test new code path for annotations
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.searchdefinition.derived;
+import com.yahoo.config.model.deploy.TestProperties;
import com.yahoo.searchdefinition.parser.ParseException;
import org.junit.Test;
@@ -13,47 +14,56 @@ public class AnnotationsTestCase extends AbstractExportingTestCase {
@Test
public void requireThatStructRegistersIfOnlyUsedByAnnotation() throws IOException, ParseException {
- assertCorrectDeriving("annotationsstruct");
+ assertCorrectDeriving("annotationsstruct",
+ new TestProperties().setExperimentalSdParsing(true));
}
@Test
public void requireThatStructRegistersIfOnlyUsedAsArrayByAnnotation() throws IOException, ParseException {
- assertCorrectDeriving("annotationsstructarray");
+ assertCorrectDeriving("annotationsstructarray",
+ new TestProperties().setExperimentalSdParsing(true));
}
@Test
public void testSimpleAnnotationDeriving() throws IOException, ParseException {
- assertCorrectDeriving("annotationssimple");
+ assertCorrectDeriving("annotationssimple",
+ new TestProperties().setExperimentalSdParsing(true));
}
@Test
public void testAnnotationDerivingWithImplicitStruct() throws IOException, ParseException {
- assertCorrectDeriving("annotationsimplicitstruct");
+ assertCorrectDeriving("annotationsimplicitstruct",
+ new TestProperties().setExperimentalSdParsing(true));
}
@Test
public void testAnnotationDerivingInheritance() throws IOException, ParseException {
- assertCorrectDeriving("annotationsinheritance");
+ assertCorrectDeriving("annotationsinheritance",
+ new TestProperties().setExperimentalSdParsing(true));
}
@Test
public void testAnnotationDerivingInheritance2() throws IOException, ParseException {
- assertCorrectDeriving("annotationsinheritance2");
+ assertCorrectDeriving("annotationsinheritance2",
+ new TestProperties().setExperimentalSdParsing(true));
}
@Test
public void testSimpleReference() throws IOException, ParseException {
- assertCorrectDeriving("annotationsreference");
+ assertCorrectDeriving("annotationsreference",
+ new TestProperties().setExperimentalSdParsing(true));
}
@Test
public void testAdvancedReference() throws IOException, ParseException {
- assertCorrectDeriving("annotationsreference2");
+ assertCorrectDeriving("annotationsreference2",
+ new TestProperties().setExperimentalSdParsing(true));
}
@Test
public void testAnnotationsPolymorphy() throws IOException, ParseException {
- assertCorrectDeriving("annotationspolymorphy");
+ assertCorrectDeriving("annotationspolymorphy",
+ new TestProperties().setExperimentalSdParsing(true));
}
/**
