diff options
author | Tor Egge <Tor.Egge@online.no> | 2023-10-31 14:24:07 +0100 |
---|---|---|
committer | Tor Egge <Tor.Egge@online.no> | 2023-10-31 14:24:07 +0100 |
commit | b9fe05eac1b6b655b28eb8ecaf18f250c1353a4e (patch) | |
tree | 1c82f762be1a38521b446632678bb13a674d57f8 /config-model/src/test | |
parent | c91d0b4f188c48f317f2029e3ec0abc05180d2f1 (diff) |
Use "document-summary" instead of "summary class" or "document summary".
Diffstat (limited to 'config-model/src/test')
5 files changed, 15 insertions, 15 deletions
diff --git a/config-model/src/test/java/com/yahoo/schema/IncorrectSummaryTypesTestCase.java b/config-model/src/test/java/com/yahoo/schema/IncorrectSummaryTypesTestCase.java index dec7b90abf0..fc649691248 100644 --- a/config-model/src/test/java/com/yahoo/schema/IncorrectSummaryTypesTestCase.java +++ b/config-model/src/test/java/com/yahoo/schema/IncorrectSummaryTypesTestCase.java @@ -30,7 +30,7 @@ public class IncorrectSummaryTypesTestCase extends AbstractSchemaTestCase { "}\n"); fail("processing should have failed"); } catch (RuntimeException e) { - assertEquals("summary somestring type string in document summary 'default' is inconsistent with summary somestring type int in document summary 'incorrect': All declarations of the same summary field must have the same type", e.getMessage()); + assertEquals("summary somestring type string in document-summary 'default' is inconsistent with summary somestring type int in document-summary 'incorrect': All declarations of the same summary field must have the same type", e.getMessage()); } } diff --git a/config-model/src/test/java/com/yahoo/schema/SummaryTestCase.java b/config-model/src/test/java/com/yahoo/schema/SummaryTestCase.java index e1dcfe70e91..4f008e661c8 100644 --- a/config-model/src/test/java/com/yahoo/schema/SummaryTestCase.java +++ b/config-model/src/test/java/com/yahoo/schema/SummaryTestCase.java @@ -65,10 +65,10 @@ public class SummaryTestCase { ApplicationBuilder.createFromString(sd, logger); assertEquals(1, logger.entries.size()); assertEquals(Level.WARNING, logger.entries.get(0).level); - assertEquals("In schema 'disksummary', document summary 'foobar': " + + assertEquals("In schema 'disksummary', document-summary 'foobar': " + "Fields [foo2] references non-attribute fields: " + "Using this summary will cause disk accesses. " + - "Set 'from-disk' on this summary class to silence this warning.", + "Set 'from-disk' on this document-summary to silence this warning.", logger.entries.get(0).message); } @@ -217,8 +217,8 @@ public class SummaryTestCase { ApplicationBuilder.createFromString(sd, logger); fail("Expected exception"); } catch (IllegalArgumentException e) { - assertEquals("For schema 'music', summary class 'title2', summary field 'title': Can not use " + - "source 'title_short' for this summary field, an equally named field in summary class 'title' " + + assertEquals("For schema 'music', document-summary 'title2', summary field 'title': Can not use " + + "source 'title_short' for this summary field, an equally named field in document-summary 'title' " + "uses a different source: 'title'.", e.getMessage()); } } @@ -235,13 +235,13 @@ public class SummaryTestCase { "}"); DeployLoggerStub logger = new DeployLoggerStub(); ApplicationBuilder.createFromStrings(logger, schema); - assertEquals("document summary 'test_summary' inherits 'nonesuch' but this is not present in schema 'test'", + assertEquals("document-summary 'test_summary' inherits 'nonesuch' but this is not present in schema 'test'", logger.entries.get(0).message); // fail("Expected failure"); } catch (IllegalArgumentException e) { fail(); - // assertEquals("document summary 'test_summary' inherits nonesuch but this is not present in schema 'test'", + // assertEquals("document-summary 'test_summary' inherits nonesuch but this is not present in schema 'test'", // e.getMessage()); } } @@ -278,8 +278,8 @@ public class SummaryTestCase { fail("Expected failure"); } catch (IllegalArgumentException e) { - assertEquals("summary field1 type string in document summary 'default' is inconsistent with " + - "summary field1 type int in document summary 'parent2': " + + assertEquals("summary field1 type string in document-summary 'default' is inconsistent with " + + "summary field1 type int in document-summary 'parent2': " + "All declarations of the same summary field must have the same type", Exceptions.toMessageString(e)); } @@ -429,7 +429,7 @@ public class SummaryTestCase { ApplicationBuilder.createFromStrings(logger, sd); fail("expected exception"); } catch (IllegalArgumentException e) { - assertEquals("For schema 'test' summary class 'bar' summary field 'foo'" + + assertEquals("For schema 'test' document-summary 'bar' summary field 'foo'" + ": Source loop detected for summary field 'foo2'", e.getMessage()); } } diff --git a/config-model/src/test/java/com/yahoo/schema/processing/MatchedElementsOnlyResolverTestCase.java b/config-model/src/test/java/com/yahoo/schema/processing/MatchedElementsOnlyResolverTestCase.java index 91cd2418eef..d15f24fd99b 100644 --- a/config-model/src/test/java/com/yahoo/schema/processing/MatchedElementsOnlyResolverTestCase.java +++ b/config-model/src/test/java/com/yahoo/schema/processing/MatchedElementsOnlyResolverTestCase.java @@ -148,7 +148,7 @@ public class MatchedElementsOnlyResolverTestCase { " summary: matched-elements-only", "}")); }); - assertTrue(exception.getMessage().contains("For schema 'test', document summary 'default', summary field 'my_field': " + + assertTrue(exception.getMessage().contains("For schema 'test', document-summary 'default', summary field 'my_field': " + "'matched-elements-only' is not supported for this field type. " + "Supported field types are: array of primitive, weighted set of primitive, " + "array of simple struct, map of primitive type to simple struct, " + diff --git a/config-model/src/test/java/com/yahoo/schema/processing/SummaryDiskAccessValidatorTestCase.java b/config-model/src/test/java/com/yahoo/schema/processing/SummaryDiskAccessValidatorTestCase.java index bac29b52949..e49a715305e 100644 --- a/config-model/src/test/java/com/yahoo/schema/processing/SummaryDiskAccessValidatorTestCase.java +++ b/config-model/src/test/java/com/yahoo/schema/processing/SummaryDiskAccessValidatorTestCase.java @@ -33,7 +33,7 @@ public class SummaryDiskAccessValidatorTestCase { ApplicationBuilder.createFromString(sd, logger); assertEquals(1, logger.warnings.size()); assertThat(logger.warnings.get(0), - containsString("In schema 'test', document summary 'my_sum': " + + containsString("In schema 'test', document-summary 'my_sum': " + "Fields [str_map] references non-attribute fields: Using this summary will cause disk accesses")); } diff --git a/config-model/src/test/java/com/yahoo/schema/processing/SummaryFieldsMustHaveValidSourceTestCase.java b/config-model/src/test/java/com/yahoo/schema/processing/SummaryFieldsMustHaveValidSourceTestCase.java index 881ad36d718..2ca53668d26 100644 --- a/config-model/src/test/java/com/yahoo/schema/processing/SummaryFieldsMustHaveValidSourceTestCase.java +++ b/config-model/src/test/java/com/yahoo/schema/processing/SummaryFieldsMustHaveValidSourceTestCase.java @@ -24,7 +24,7 @@ public class SummaryFieldsMustHaveValidSourceTestCase extends AbstractSchemaTest ApplicationBuilder.buildFromFile("src/test/examples/invalidsummarysource.sd"); fail("This should throw and never get here"); } catch (IllegalArgumentException e) { - assertEquals("For schema 'invalidsummarysource', summary class 'baz', summary field 'cox': there is no valid source 'nonexistingfield'.", e.getMessage()); + assertEquals("For schema 'invalidsummarysource', document-summary 'baz', summary field 'cox': there is no valid source 'nonexistingfield'.", e.getMessage()); } } @@ -34,7 +34,7 @@ public class SummaryFieldsMustHaveValidSourceTestCase extends AbstractSchemaTest ApplicationBuilder.buildFromFile("src/test/examples/invalidimplicitsummarysource.sd"); fail("This should throw and never get here"); } catch (IllegalArgumentException e) { - assertEquals("For schema 'invalidsummarysource', summary class 'baz', summary field 'cox': there is no valid source 'cox'.", e.getMessage()); + assertEquals("For schema 'invalidsummarysource', document-summary 'baz', summary field 'cox': there is no valid source 'cox'.", e.getMessage()); } } @@ -44,7 +44,7 @@ public class SummaryFieldsMustHaveValidSourceTestCase extends AbstractSchemaTest ApplicationBuilder.buildFromFile("src/test/examples/invalidselfreferringsummary.sd"); fail("This should throw and never get here"); } catch (IllegalArgumentException e) { - assertEquals("For schema 'invalidselfreferringsummary', summary class 'withid', summary field 'w': there is no valid source 'w'.", e.getMessage()); + assertEquals("For schema 'invalidselfreferringsummary', document-summary 'withid', summary field 'w': there is no valid source 'w'.", e.getMessage()); } } |