summaryrefslogtreecommitdiffstats
path: root/config-model/src/test/java/com/yahoo/searchdefinition/derived/SchemaInheritanceTestCase.java
diff options
context:
space:
mode:
authorJon Bratseth <bratseth@gmail.com>2021-10-20 12:22:21 +0200
committerJon Bratseth <bratseth@gmail.com>2021-10-20 12:22:21 +0200
commit8f27baa4aba7ec98e39db5f701bf652e42faefa6 (patch)
tree9bd32a98be03bab55a8f111437db1611bfc75748 /config-model/src/test/java/com/yahoo/searchdefinition/derived/SchemaInheritanceTestCase.java
parent8d337646d3f06b6ad987e4b3a8d7fda230726d00 (diff)
Prep for test of deriving with schema inheritance
Diffstat (limited to 'config-model/src/test/java/com/yahoo/searchdefinition/derived/SchemaInheritanceTestCase.java')
-rw-r--r--config-model/src/test/java/com/yahoo/searchdefinition/derived/SchemaInheritanceTestCase.java28
1 files changed, 28 insertions, 0 deletions
diff --git a/config-model/src/test/java/com/yahoo/searchdefinition/derived/SchemaInheritanceTestCase.java b/config-model/src/test/java/com/yahoo/searchdefinition/derived/SchemaInheritanceTestCase.java
new file mode 100644
index 00000000000..25195587cd2
--- /dev/null
+++ b/config-model/src/test/java/com/yahoo/searchdefinition/derived/SchemaInheritanceTestCase.java
@@ -0,0 +1,28 @@
+// 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.application.provider.MockFileRegistry;
+import com.yahoo.config.model.deploy.TestProperties;
+import com.yahoo.searchdefinition.RankProfileRegistry;
+import com.yahoo.searchdefinition.SearchBuilder;
+import com.yahoo.searchdefinition.parser.ParseException;
+import org.junit.Test;
+
+import java.io.IOException;
+
+/**
+ * @author bratseth
+ */
+public class SchemaInheritanceTestCase extends AbstractExportingTestCase {
+
+ @Test
+ public void testIt() throws IOException, ParseException {
+ SearchBuilder builder = SearchBuilder.createFromDirectory("src/test/derived/schemainheritance/",
+ new MockFileRegistry(),
+ new TestableDeployLogger(),
+ new TestProperties());
+ derive("schemainheritance", builder, builder.getSearch("child"));
+ assertCorrectConfigFiles("schemainheritance");
+ }
+
+}