From b12e8f5fd7f6ff4469b006043ee1dc36534123af Mon Sep 17 00:00:00 2001 From: AlexanderSashchenko <58402322+AlexanderSashchenko@users.noreply.github.com> Date: Wed, 4 Oct 2023 17:20:46 +0300 Subject: [PATCH] Added support for Test-harness FoundationalCompatibility (#110) * Added support for Test-harness FoundationalCompatibility (Basic+Foundational) * added test-harness resources files * changed test-harness version to 1.0.8 (future release) * fix pom * fix pom * Fix renamed import * Removes json dependency --------- Co-authored-by: filipe --- pom.xml | 7 +- ...rnessFoundationalCompatibilitySuite.groovy | 4 ++ .../redshift/createTable.json | 52 ++++++++++++++ .../setup.redshift/createTable.xml | 71 +++++++++++++++++++ 4 files changed, 133 insertions(+), 1 deletion(-) create mode 100644 src/test/groovy/LiquibaseHarnessFoundationalCompatibilitySuite.groovy create mode 100644 src/test/resources/liquibase/harness/compatibility/basic/expectedResultSet/redshift/createTable.json create mode 100644 src/test/resources/liquibase/harness/compatibility/foundational/setup.redshift/createTable.xml diff --git a/pom.xml b/pom.xml index b382b8c..3160f41 100644 --- a/pom.xml +++ b/pom.xml @@ -138,6 +138,11 @@ + + org.skyscreamer + jsonassert + 1.5.1 + com.athaydes spock-reports @@ -284,4 +289,4 @@ - \ No newline at end of file + diff --git a/src/test/groovy/LiquibaseHarnessFoundationalCompatibilitySuite.groovy b/src/test/groovy/LiquibaseHarnessFoundationalCompatibilitySuite.groovy new file mode 100644 index 0000000..eedcfc3 --- /dev/null +++ b/src/test/groovy/LiquibaseHarnessFoundationalCompatibilitySuite.groovy @@ -0,0 +1,4 @@ +import liquibase.harness.FoundationalHarnessSuite + +class LiquibaseHarnessFoundationalCompatibilitySuite extends FoundationalHarnessSuite { +} diff --git a/src/test/resources/liquibase/harness/compatibility/basic/expectedResultSet/redshift/createTable.json b/src/test/resources/liquibase/harness/compatibility/basic/expectedResultSet/redshift/createTable.json new file mode 100644 index 0000000..356dc00 --- /dev/null +++ b/src/test/resources/liquibase/harness/compatibility/basic/expectedResultSet/redshift/createTable.json @@ -0,0 +1,52 @@ +{ + "createTable": [ + { + "comments": "test_comment", + "author": "as", + "description": "sql", + "contexts": "test_context", + "exectype": "EXECUTED", + "labels": "test_label", + "filename": "liquibase\/harness\/compatibility\/basic\/changelogs\/createTable.xml", + "md5sum": "8:4e697074d57029d3e267ce7507da5cf5", + "id": "1", + "tag": "" + }, + { + "comments": "test_comment", + "author": "as", + "description": "createTable tableName=test_table_yaml", + "contexts": "test_context", + "exectype": "EXECUTED", + "labels": "test_label", + "filename": "liquibase\/harness\/compatibility\/basic\/changelogs\/createTable.yml", + "md5sum": "8:13bf5dadad410884e263691bc66ee760", + "id": "1", + "tag": "" + }, + { + "comments": "test_comment", + "author": "as", + "description": "sql", + "contexts": "test_context", + "exectype": "EXECUTED", + "labels": "test_label", + "filename": "liquibase\/harness\/compatibility\/basic\/changelogs\/createTable.sql", + "md5sum": "8:3e89383340c9b7c69e4902c53534b7ac", + "id": "1", + "tag": "test_tag" + }, + { + "comments": "test_comment", + "author": "as", + "description": "createTable tableName=test_table_json", + "contexts": "test_context", + "exectype": "EXECUTED", + "labels": "test_label", + "filename": "liquibase\/harness\/compatibility\/basic\/changelogs\/createTable.json", + "md5sum": "8:b9ab89365e024967a1da5704f0441428", + "id": "1", + "tag": "" + } + ] +} \ No newline at end of file diff --git a/src/test/resources/liquibase/harness/compatibility/foundational/setup.redshift/createTable.xml b/src/test/resources/liquibase/harness/compatibility/foundational/setup.redshift/createTable.xml new file mode 100644 index 0000000..64b2e39 --- /dev/null +++ b/src/test/resources/liquibase/harness/compatibility/foundational/setup.redshift/createTable.xml @@ -0,0 +1,71 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + labels='foundational' + + + + \ No newline at end of file