diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 0000000..715d69d --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,45 @@ +name: Build and Test + +on: + merge_group: + workflow_dispatch: + pull_request: + types: + - opened + - synchronize + push: + branches: + - master + +permissions: + contents: read + +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: ${{ github.ref != 'refs/heads/master' }} + +jobs: + build: + runs-on: ubuntu-latest + strategy: + matrix: + node: [ 12, 14, 16 ] + name: Node ${{ matrix.node }} Test + steps: + - name: Checkout code + uses: actions/checkout@v4 + with: + ref: ${{ github.event.pull_request.head.sha || github.ref }} + + - name: Setup Node + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node }} + cache: 'npm' + + - name: Install dependencies + run: npm ci + + - name: Run Mocha unit tests + run: npm run test + diff --git a/README.md b/README.md index 3fa5fb3..9b77964 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,9 @@ W3C XML Encryption implementation for node.js (http://www.w3.org/TR/xmlenc-core/) -Supports node >= 12 +Supports node >= 12 < 18 + +node 18 not supported due to https://github.com/nodejs/node/issues/52017 for Triple DES algorithms. ## Usage diff --git a/package.json b/package.json index 6743efd..e388f21 100644 --- a/package.json +++ b/package.json @@ -32,6 +32,6 @@ "test": "mocha" }, "engines": { - "node": ">=12" + "node": ">=12 < 18" } }