aboutsummaryrefslogtreecommitdiffstats
path: root/config-model/src/test
diff options
context:
space:
mode:
authorHarald Musum <musum@verizonmedia.com>2019-07-15 11:05:17 +0200
committerGitHub <noreply@github.com>2019-07-15 11:05:17 +0200
commitb120c86034342e38a71ca684a8391c34452e4f01 (patch)
tree38b5d452c5ef2a6cf4b8bb0054bf53b41801049b /config-model/src/test
parentec17f2b9d074a8d96a3372c55064aa2591586ba0 (diff)
Revert "Setting attribute on a field that has struct or map sub-type(s) is no…"
Diffstat (limited to 'config-model/src/test')
-rw-r--r--config-model/src/test/java/com/yahoo/vespa/model/application/validation/ComplexAttributeFieldsValidatorTestCase.java30
1 files changed, 0 insertions, 30 deletions
diff --git a/config-model/src/test/java/com/yahoo/vespa/model/application/validation/ComplexAttributeFieldsValidatorTestCase.java b/config-model/src/test/java/com/yahoo/vespa/model/application/validation/ComplexAttributeFieldsValidatorTestCase.java
index a0c05193661..3ba3745f46e 100644
--- a/config-model/src/test/java/com/yahoo/vespa/model/application/validation/ComplexAttributeFieldsValidatorTestCase.java
+++ b/config-model/src/test/java/com/yahoo/vespa/model/application/validation/ComplexAttributeFieldsValidatorTestCase.java
@@ -49,36 +49,6 @@ public class ComplexAttributeFieldsValidatorTestCase {
}
@Test
- public void throws_when_attribute_is_set_on_a_field_with_struct_sub_type() throws IOException, SAXException {
- exceptionRule.expect(IllegalArgumentException.class);
- exceptionRule.expectMessage("For field 'struct_array.f2': Setting attribute on a field that has struct or map sub-type(s) is not supported");
- createModelAndValidate(joinLines(createSearchDefintionWithInvalidStructFieldAttribute("array<s1>")));
- }
-
- @Test
- public void throws_when_attribute_is_set_on_a_field_with_map_sub_type() throws IOException, SAXException {
- exceptionRule.expect(IllegalArgumentException.class);
- exceptionRule.expectMessage("For field 'struct_array.f2': Setting attribute on a field that has struct or map sub-type(s) is not supported");
- createModelAndValidate(joinLines(createSearchDefintionWithInvalidStructFieldAttribute("map<string, int>")));
- }
-
- private String createSearchDefintionWithInvalidStructFieldAttribute(String invalidFieldType) {
- return joinLines("search test {",
- " document test {",
- " struct s1 {",
- " field f1 type int {}",
- " }",
- " struct s2 {",
- " field f2 type " + invalidFieldType + " {}",
- " }",
- " field struct_array type array<s2> {",
- " struct-field f2 { indexing: attribute }",
- " }",
- " }",
- "}");
- }
-
- @Test
public void validation_passes_when_only_supported_struct_field_attributes_are_used() throws IOException, SAXException {
createModelAndValidate(joinLines("search test {",
" document test {",