From 5b7ec40ee39763d11fe2b6a6e1cbc221c21dc2b3 Mon Sep 17 00:00:00 2001 From: Ryan Lubke Date: Fri, 21 Jul 2023 09:30:27 -0700 Subject: [PATCH 1/7] Bump coherence testing to latest CE releases. --- .github/workflows/node.js.yml | 2 +- bin/docker-utils.sh | 2 +- test/util.js | 15 +++++++++++++-- 3 files changed, 15 insertions(+), 4 deletions(-) diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index a92abec..8e44068 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -29,7 +29,7 @@ jobs: fail-fast: false matrix: node-version: [18.15.x, 19.x] - coherence-version: [22.06.2, 23.03] + coherence-version: [22.06.5, 23.03.1] steps: - uses: actions/checkout@v3 diff --git a/bin/docker-utils.sh b/bin/docker-utils.sh index d26bd22..b901479 100755 --- a/bin/docker-utils.sh +++ b/bin/docker-utils.sh @@ -7,7 +7,7 @@ set -e -declare VERSION=${COHERENCE_VERSION:=22.06.2} +declare VERSION=${COHERENCE_VERSION:=22.06.5} function coh_up() { echo "Starting test containers ..." diff --git a/test/util.js b/test/util.js index 49c2cd5..d55b08b 100644 --- a/test/util.js +++ b/test/util.js @@ -7,13 +7,24 @@ const Decimal = require("decimal.js"); const assert = require('assert').strict -const COHERENCE_VERSION = "COHERENCE_VERSION" in process.env ? process.env.COHERENCE_VERSION : "22.06" +const COHERENCE_VERSION = "COHERENCE_VERSION" in process.env ? process.env.COHERENCE_VERSION : "22.06.5" module.exports = { COHERENCE_VERSION, checkNumericResult: function (result, expected) { - let numberResultExpected = COHERENCE_VERSION.startsWith("22.06") + let numberResultExpected = false + let is2206= COHERENCE_VERSION.startsWith("22.06") + if (is2206) { + let parts= COHERENCE_VERSION.split(".") + if (parts.length === 2) { + numberResultExpected = true + } else if (parts.length === 3) { + if (Number(parts[2]) >= 4) { + numberResultExpected = false + } + } + } if (numberResultExpected && typeof(result) === 'number') { assert.equal(result, expected) From 85cf836777af922c2dd2eb83a601c0c94f47efd1 Mon Sep 17 00:00:00 2001 From: Ryan Lubke Date: Fri, 21 Jul 2023 09:38:42 -0700 Subject: [PATCH 2/7] Bump coherence testing to latest CE releases. --- bin/docker-utils.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/docker-utils.sh b/bin/docker-utils.sh index b901479..d32bbcc 100755 --- a/bin/docker-utils.sh +++ b/bin/docker-utils.sh @@ -17,6 +17,7 @@ function coh_up() { while [ ${SECONDS} -le 60 ]; do READY=$(curl -o /dev/null -s -w "%{http_code}" "http://127.0.0.1:6676/ready") || true if [ "${READY}" -eq "200" ]; then + sleep 5 echo "Coherence is ready!" return fi From 047806c48b5adadedbefe3db1ddbf57dfd781bad Mon Sep 17 00:00:00 2001 From: Ryan Lubke Date: Fri, 21 Jul 2023 09:43:02 -0700 Subject: [PATCH 3/7] Bump coherence testing to latest CE releases. --- .github/workflows/release.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ac22eeb..322b401 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -37,8 +37,8 @@ jobs: - run: echo "/tmp/grpc/bin" >> $GITHUB_PATH - run: npm install # run unit tests - - run: COHERENCE_VERSION=22.06.2 npm run test-cycle - - run: COHERENCE_VERSION=23.03 npm run test-cycle + - run: COHERENCE_VERSION=22.06.5 npm run test-cycle + - run: COHERENCE_VERSION=23.03.1 npm run test-cycle - run: npm install --no-save typedoc # generate dist which runs other tasks - run: npm run dist From dedaeefbfce22053ea2bc39ce781149671a3b6c0 Mon Sep 17 00:00:00 2001 From: Ryan Lubke Date: Fri, 21 Jul 2023 09:43:38 -0700 Subject: [PATCH 4/7] Bump coherence testing to latest CE releases. --- .github/workflows/node.js.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index 8e44068..51661fa 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -29,7 +29,7 @@ jobs: fail-fast: false matrix: node-version: [18.15.x, 19.x] - coherence-version: [22.06.5, 23.03.1] + coherence-version: [22.06, 22.06.5, 23.03.1] steps: - uses: actions/checkout@v3 From c063bed5d9b00a346a730fdaa33d754e63fb522d Mon Sep 17 00:00:00 2001 From: Ryan Lubke Date: Fri, 21 Jul 2023 09:54:17 -0700 Subject: [PATCH 5/7] Bump coherence testing to latest CE releases. --- .github/workflows/node.js.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index 51661fa..8e44068 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -29,7 +29,7 @@ jobs: fail-fast: false matrix: node-version: [18.15.x, 19.x] - coherence-version: [22.06, 22.06.5, 23.03.1] + coherence-version: [22.06.5, 23.03.1] steps: - uses: actions/checkout@v3 From 3c2d2ed4093a80acd0cc22e7ff604d56c625d70c Mon Sep 17 00:00:00 2001 From: Ryan Lubke Date: Fri, 21 Jul 2023 09:55:55 -0700 Subject: [PATCH 6/7] Bump coherence testing to latest CE releases. --- test/util.js | 23 ++--------------------- 1 file changed, 2 insertions(+), 21 deletions(-) diff --git a/test/util.js b/test/util.js index d55b08b..94be545 100644 --- a/test/util.js +++ b/test/util.js @@ -7,30 +7,11 @@ const Decimal = require("decimal.js"); const assert = require('assert').strict -const COHERENCE_VERSION = "COHERENCE_VERSION" in process.env ? process.env.COHERENCE_VERSION : "22.06.5" - module.exports = { - COHERENCE_VERSION, - checkNumericResult: function (result, expected) { - let numberResultExpected = false - let is2206= COHERENCE_VERSION.startsWith("22.06") - if (is2206) { - let parts= COHERENCE_VERSION.split(".") - if (parts.length === 2) { - numberResultExpected = true - } else if (parts.length === 3) { - if (Number(parts[2]) >= 4) { - numberResultExpected = false - } - } - } - - if (numberResultExpected && typeof(result) === 'number') { - assert.equal(result, expected) - } else if (!numberResultExpected && result instanceof Decimal) { + if (result instanceof Decimal) { assert.deepStrictEqual(result, new Decimal(expected)) - } else if (!numberResultExpected && typeof(result) === 'bigint') { + } else if (typeof(result) === 'bigint') { assert.deepStrictEqual(result, BigInt(expected)) } else { assert(false, "Unexpected result type [" + typeof(result) + "]") From a03173e2ab15898ee320515cd6a0691b1cf163db Mon Sep 17 00:00:00 2001 From: Ryan Lubke Date: Fri, 21 Jul 2023 09:59:18 -0700 Subject: [PATCH 7/7] Bump coherence testing to latest CE releases. --- test/serialization-tests.js | 5 ----- 1 file changed, 5 deletions(-) diff --git a/test/serialization-tests.js b/test/serialization-tests.js index b8c8288..3164c70 100644 --- a/test/serialization-tests.js +++ b/test/serialization-tests.js @@ -119,11 +119,6 @@ describe('Serialization Unit/Integration Test Suite', () => { }) describe("Serialization Integration Tests", () => { - if (test.COHERENCE_VERSION.startsWith("22.06")) { - it("are skipped if running against 22.06", () => {} ) - return - } - const session = new Session() const cache = session.getCache("test-ser")