Skip to content

Commit

Permalink
chore: GitHub Action cleanup & run tests on valkey
Browse files Browse the repository at this point in the history
Signed-off-by: Matteo Collina <[email protected]>
  • Loading branch information
mcollina committed Jun 14, 2024
1 parent 2733aee commit 3ab96d4
Show file tree
Hide file tree
Showing 3 changed files with 43 additions and 43 deletions.
30 changes: 0 additions & 30 deletions .github/workflows/release.yml

This file was deleted.

51 changes: 40 additions & 11 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,20 @@
on:
workflow_call:
push:
paths-ignore:
- 'docs/**'
- '*.md'
pull_request:
paths-ignore:
- 'docs/**'
- '*.md'

jobs:
test:
test-redis:
runs-on: ubuntu-latest
strategy:
fail-fast: false
fail-fast: true
matrix:
node: [12.x, 14.x, 16.x, 18.x, 20.x]
node: [18.x, 20.x, 22.x]
steps:
- name: Git checkout
uses: actions/checkout@v2
Expand All @@ -27,13 +34,6 @@ jobs:
- run: npm run build
- run: npm run test:tsd
- run: npm run test:cov || npm run test:cov || npm run test:cov
- name: Coveralls
if: matrix.node == '20.x'
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
flag-name: node-${{matrix.node}}
parallel: true

test-cluster:
runs-on: ubuntu-latest
Expand All @@ -42,6 +42,35 @@ jobs:
- name: Build and test cluster
run: bash test/cluster/docker/main.sh

test-valkey:
runs-on: ubuntu-latest
strategy:
fail-fast: true
matrix:
node: [18.x, 20.x, 22.x]

services:
valkey:
image: valkey/valkey:latest
ports:
# Opens tcp port 6379 on the host and service container
- 6379:6379

steps:
- name: Git checkout
uses: actions/checkout@v2

- name: Use Node.js ${{ matrix.node }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node }}

- run: npm install
- run: npm run lint
- run: npm run build
- run: npm run test:tsd
- run: npm run test:cov || npm run test:cov || npm run test:cov

code-coverage:
needs: test
runs-on: ubuntu-latest
Expand Down
5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,12 @@
"format": "prettier --write \"{,!(node_modules)/**/}*.{js,ts}\"",
"format-check": "prettier --check \"{,!(node_modules)/**/}*.{js,ts}\"",
"build": "rm -rf built && tsc",
"prepublishOnly": "npm run build"
"prepublishOnly": "npm run build",
"start-valkey": "docker run -p 6379:6379 valkey/valkey"
},
"repository": {
"type": "git",
"url": "git://github.com/mcollina/iovalkey.git"
"url": "git://github.com/valkey/iovalkey.git"
},
"keywords": [
"redis",
Expand Down

0 comments on commit 3ab96d4

Please sign in to comment.