From dd8eb264d741a54aa490c640095fac3e78894b9d Mon Sep 17 00:00:00 2001 From: salamonpavel Date: Thu, 14 Nov 2024 15:24:14 +0100 Subject: [PATCH] agent-server tests (#301) agent server compatibility tests --- .github/workflows/test_filenames_check.yml | 2 +- .sbtrc | 3 +++ ...grationTests.scala => AgentServerCompatibilityTests.scala} | 4 ++-- 3 files changed, 6 insertions(+), 3 deletions(-) rename agent/src/test/scala/za/co/absa/atum/agent/{AgentWithServerIntegrationTests.scala => AgentServerCompatibilityTests.scala} (97%) diff --git a/.github/workflows/test_filenames_check.yml b/.github/workflows/test_filenames_check.yml index d3e24ee2f..ed0a061af 100644 --- a/.github/workflows/test_filenames_check.yml +++ b/.github/workflows/test_filenames_check.yml @@ -33,7 +33,7 @@ jobs: id: scan-test-files uses: AbsaOSS/filename-inspector@v0.1.0 with: - name-patterns: '*UnitTests.*,*IntegrationTests.*' + name-patterns: '*UnitTests.*,*IntegrationTests.*,*CompatibilityTests.*' paths: '**/src/test/scala/**' report-format: 'console' excludes: | diff --git a/.sbtrc b/.sbtrc index 12237cb88..c89544c91 100644 --- a/.sbtrc +++ b/.sbtrc @@ -30,3 +30,6 @@ alias testDB=; project database; testOnly * # Run all tests alias testAll=; testOnly * + +# Run agent-server compatibility tests +alias testCompatibility=; testOnly *CompatibilityTests diff --git a/agent/src/test/scala/za/co/absa/atum/agent/AgentWithServerIntegrationTests.scala b/agent/src/test/scala/za/co/absa/atum/agent/AgentServerCompatibilityTests.scala similarity index 97% rename from agent/src/test/scala/za/co/absa/atum/agent/AgentWithServerIntegrationTests.scala rename to agent/src/test/scala/za/co/absa/atum/agent/AgentServerCompatibilityTests.scala index 191a987a6..992aabe12 100644 --- a/agent/src/test/scala/za/co/absa/atum/agent/AgentWithServerIntegrationTests.scala +++ b/agent/src/test/scala/za/co/absa/atum/agent/AgentServerCompatibilityTests.scala @@ -26,7 +26,7 @@ import za.co.absa.atum.agent.dispatcher.HttpDispatcher import scala.collection.immutable.ListMap -class AgentWithServerIntegrationTests extends DBTestSuite { +class AgentServerCompatibilityTests extends DBTestSuite { private val testDataForRDD = Seq( Row("A", 8.0), @@ -40,7 +40,7 @@ class AgentWithServerIntegrationTests extends DBTestSuite { .add(StructField("columnForSum", DoubleType)) // Need to add service & pg run in CI - ignore("Agent should be compatible with server") { + test("Agent should be compatible with server") { val expectedMeasurement = JsonBString( """{"mainValue": {"value": "4", "valueType": "Long"}, "supportValues": {}}""".stripMargin