commit | 438293f5ff8bb37f218eda3697dd7b8b54918624 | [log] [tgz] |
---|---|---|
author | Nguyen Tuan Khang Phan <nguyen.tuan.khang.phan@ericsson.com> | Thu May 13 18:49:57 2021 -0400 |
committer | Nguyen Tuan Khang Phan <phan.khang5@gmail.com> | Fri May 21 17:27:54 2021 +0000 |
tree | 41f05640dd315d0b1510c1a75f80329fedf521ec | |
parent | 14112f4ae264a32b7fd053e0c522c0a31b7e262a [diff] |
e2e-tests: Fix regex to adapt to JSON_COMPACT Since stable-3.1 JSON responses output COMPACT_JSON unconditionally. Apply the same fix as done in commit [1]. [1] commit cda42da487dd97c017e30053e9a8b4b4168b90d6 Change-Id: I9bd037ea02d68ea8a1d574410347037f93b14dea
diff --git a/src/test/scala/com/ericsson/gerrit/plugins/highavailability/scenarios/CheckProjectsCacheFlushEntriesUsingHAGerrit1.scala b/src/test/scala/com/ericsson/gerrit/plugins/highavailability/scenarios/CheckProjectsCacheFlushEntriesUsingHAGerrit1.scala index 6a0d07f..7e63134 100644 --- a/src/test/scala/com/ericsson/gerrit/plugins/highavailability/scenarios/CheckProjectsCacheFlushEntriesUsingHAGerrit1.scala +++ b/src/test/scala/com/ericsson/gerrit/plugins/highavailability/scenarios/CheckProjectsCacheFlushEntriesUsingHAGerrit1.scala
@@ -42,7 +42,7 @@ } }) .exec(http(uniqueName).get("${url}") - .check(regex("\"" + memKey + "\": (\\d+)") + .check(regex("\"" + memKey + "\":(\\d+)") .is(session => session(entriesKey).as[String]))) setUp(
diff --git a/src/test/scala/com/ericsson/gerrit/plugins/highavailability/scenarios/GetProjectsCacheEntries.scala b/src/test/scala/com/ericsson/gerrit/plugins/highavailability/scenarios/GetProjectsCacheEntries.scala index ed19c0b..8a04245 100644 --- a/src/test/scala/com/ericsson/gerrit/plugins/highavailability/scenarios/GetProjectsCacheEntries.scala +++ b/src/test/scala/com/ericsson/gerrit/plugins/highavailability/scenarios/GetProjectsCacheEntries.scala
@@ -31,7 +31,7 @@ val test: ScenarioBuilder = scenario(uniqueName) .feed(data) .exec(http(uniqueName).get("${url}") - .check(regex("\"" + memKey + "\": (\\d+)").saveAs(entriesKey))) + .check(regex("\"" + memKey + "\":(\\d+)").saveAs(entriesKey))) .exec(session => { if (consumer.nonEmpty) { consumer.get.entriesBeforeFlush(session(entriesKey).as[Int])