Peter Centgraf pushed to branch feature/hcm at cms-community / hippo-repository
Commits: be464a85 by Peter Centgraf at 2017-06-06T11:49:21+02:00 REPO-1687 Refactor DefinitionMergeTest$MergeTest to ...$MergeFixture and make it clear it is not a runnable test itself - - - - - 1 changed file: - engine/src/test/java/org/onehippo/cm/engine/autoexport/DefinitionMergeTest.java Changes: ===================================== engine/src/test/java/org/onehippo/cm/engine/autoexport/DefinitionMergeTest.java ===================================== --- a/engine/src/test/java/org/onehippo/cm/engine/autoexport/DefinitionMergeTest.java +++ b/engine/src/test/java/org/onehippo/cm/engine/autoexport/DefinitionMergeTest.java @@ -27,6 +27,7 @@ import java.util.Set; import org.junit.Rule; import org.junit.Test; import org.junit.rules.TemporaryFolder; +import org.onehippo.cm.model.AbstractBaseTest; import org.onehippo.cm.model.Constants; import org.onehippo.cm.model.FileConfigurationWriter; import org.onehippo.cm.model.ModuleContext; @@ -49,52 +50,52 @@ public class DefinitionMergeTest { @Test public void template_works() throws Exception { - new MergeTest("template").test(); + new MergeFixture("template").test(); } @Test public void create_and_update_namespaces() throws Exception { - new MergeTest("namespace").test(); + new MergeFixture("namespace").test(); } @Test public void new_node() throws Exception { - new MergeTest("new-node").test(); + new MergeFixture("new-node").test(); } @Test public void delete_node() throws Exception { - new MergeTest("delete-node").test(); + new MergeFixture("delete-node").test(); } @Test public void add_property() throws Exception { - new MergeTest("add-property").test(); + new MergeFixture("add-property").test(); } @Test public void append_property() throws Exception { - new MergeTest("append-property").test(); + new MergeFixture("append-property").test(); } @Test public void delete_property() throws Exception { - new MergeTest("delete-property").test(); + new MergeFixture("delete-property").test(); } @Test public void override_property() throws Exception { - new MergeTest("override-property").test(); + new MergeFixture("override-property").test(); } - public class MergeTest extends SerializerTest { + public class MergeFixture extends AbstractBaseTest { String testName; String[] base = {"topmost", "upstream"}; String[] toExport = {"exportFirst", "exportSecond"}; Configuration autoExportConfig; - public MergeTest(final String testName) { + public MergeFixture(final String testName) { this.testName = testName; Map<String, Collection<String>> modules = new HashMap<>(); @@ -103,17 +104,17 @@ public class DefinitionMergeTest { autoExportConfig = AutoExportConfigFactory.make(true, modules); } - public MergeTest base(final String... base) { + public MergeFixture base(final String... base) { this.base = base; return this; } - public MergeTest toExport(final String... toExport) { + public MergeFixture toExport(final String... toExport) { this.toExport = toExport; return this; } - public MergeTest config(final Configuration config) { + public MergeFixture config(final Configuration config) { this.autoExportConfig = config; return this; } View it on GitLab: https://code.onehippo.org/cms-community/hippo-repository/commit/be464a85bf9e9631a21901593ddfb8d9d65471b5
_______________________________________________ Hippocms-svn mailing list Hippocms-svn@lists.onehippo.org https://lists.onehippo.org/mailman/listinfo/hippocms-svn