diff options
Diffstat (limited to 'container-search/src/test/java/com/yahoo/search/query/properties/test/RequestContextPropertiesTestCase.java')
-rw-r--r-- | container-search/src/test/java/com/yahoo/search/query/properties/test/RequestContextPropertiesTestCase.java | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/container-search/src/test/java/com/yahoo/search/query/properties/test/RequestContextPropertiesTestCase.java b/container-search/src/test/java/com/yahoo/search/query/properties/test/RequestContextPropertiesTestCase.java index 2a123b4bbda..23b41092660 100644 --- a/container-search/src/test/java/com/yahoo/search/query/properties/test/RequestContextPropertiesTestCase.java +++ b/container-search/src/test/java/com/yahoo/search/query/properties/test/RequestContextPropertiesTestCase.java @@ -5,9 +5,9 @@ import com.yahoo.search.Query; import com.yahoo.search.query.profile.QueryProfile; import com.yahoo.search.query.profile.QueryProfileRegistry; import com.yahoo.search.test.QueryTestCase; -import org.junit.Test; +import org.junit.jupiter.api.Test; -import static org.junit.Assert.assertEquals; +import static org.junit.jupiter.api.Assertions.assertEquals; /** * Tests that dimension arguments in queries are transferred correctly to dimension values @@ -17,18 +17,18 @@ import static org.junit.Assert.assertEquals; public class RequestContextPropertiesTestCase { @Test - public void testIt() { - QueryProfile p=new QueryProfile("test"); - p.setDimensions(new String[] {"x"}); - p.set("a","a-default", (QueryProfileRegistry)null); - p.set("a","a-x1",new String[] {"x1"}, null); - p.set("a","a-+x1",new String[] {"+x1"}, null); + void testIt() { + QueryProfile p = new QueryProfile("test"); + p.setDimensions(new String[]{"x"}); + p.set("a", "a-default", (QueryProfileRegistry) null); + p.set("a", "a-x1", new String[]{"x1"}, null); + p.set("a", "a-+x1", new String[]{"+x1"}, null); Query q1 = new Query(QueryTestCase.httpEncode("?query=foo"), p.compile(null)); - assertEquals("a-default",q1.properties().get("a")); - Query q2 = new Query(QueryTestCase.httpEncode("?query=foo&x=x1"),p.compile(null)); - assertEquals("a-x1",q2.properties().get("a")); - Query q3 = new Query(QueryTestCase.httpEncode("?query=foo&x=+x1"),p.compile(null)); - assertEquals("a-+x1",q3.properties().get("a")); + assertEquals("a-default", q1.properties().get("a")); + Query q2 = new Query(QueryTestCase.httpEncode("?query=foo&x=x1"), p.compile(null)); + assertEquals("a-x1", q2.properties().get("a")); + Query q3 = new Query(QueryTestCase.httpEncode("?query=foo&x=+x1"), p.compile(null)); + assertEquals("a-+x1", q3.properties().get("a")); } } |