aboutsummaryrefslogtreecommitdiffstats
path: root/config-model/src/test/java/com/yahoo/schema/processing
diff options
context:
space:
mode:
Diffstat (limited to 'config-model/src/test/java/com/yahoo/schema/processing')
-rw-r--r--config-model/src/test/java/com/yahoo/schema/processing/NGramTestCase.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/config-model/src/test/java/com/yahoo/schema/processing/NGramTestCase.java b/config-model/src/test/java/com/yahoo/schema/processing/NGramTestCase.java
index 06ea202b9c3..551542a84ba 100644
--- a/config-model/src/test/java/com/yahoo/schema/processing/NGramTestCase.java
+++ b/config-model/src/test/java/com/yahoo/schema/processing/NGramTestCase.java
@@ -27,15 +27,15 @@ public class NGramTestCase extends AbstractSchemaTestCase {
SDField gram1 = schema.getConcreteField("gram_1");
assertEquals(MatchType.GRAM, gram1.getMatching().getType());
- assertEquals(1, gram1.getMatching().getGramSize());
+ assertEquals(1, gram1.getMatching().getGramSize().getAsInt());
SDField gram2 = schema.getConcreteField("gram_2");
assertEquals(MatchType.GRAM, gram2.getMatching().getType());
- assertEquals(-1, gram2.getMatching().getGramSize()); // Not set explicitly
+ assertTrue(gram2.getMatching().getGramSize().isEmpty());
SDField gram3 = schema.getConcreteField("gram_3");
assertEquals(MatchType.GRAM, gram3.getMatching().getType());
- assertEquals(3, gram3.getMatching().getGramSize());
+ assertEquals(3, gram3.getMatching().getGramSize().getAsInt());
assertEquals("input gram_1 | ngram 1 | index gram_1 | summary gram_1", gram1.getIndexingScript().iterator().next().toString());
assertEquals("input gram_2 | ngram 2 | attribute gram_2 | index gram_2", gram2.getIndexingScript().iterator().next().toString());