Build(deps): Bump supercharge/redis-github-action from 1.7.0 to 1.8.0 #718
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: test | |
on: | |
push: | |
branches: [master, canary] | |
pull_request: | |
branches: [master, canary] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [16, 18] | |
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/ | |
env: | |
MYSQL_DB_DATABASE: keyv_test | |
MYSQL_DB_USER: root | |
MYSQL_DB_PASSWORD: root | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Use Node.js ${{ matrix.node-version }} | |
uses: actions/setup-node@v4 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Start Redis | |
uses: supercharge/[email protected] | |
# - name: Start PostgreSQL | |
# uses: harmon758/postgresql-action@v1 | |
# with: | |
# postgresql version: '11' | |
# postgresql password: postgres | |
# postgresql user: postgres | |
# postgresql db: keyv_test | |
- name: Start MongoDB | |
uses: supercharge/[email protected] | |
- name: Start MySQL | |
run: | | |
sudo systemctl start mysql.service | |
mysql -e 'CREATE DATABASE ${{ env.MYSQL_DB_DATABASE }}' -u${{ env.MYSQL_DB_USER }} -p${{ env.MYSQL_DB_PASSWORD }} | |
mysql -e 'SET GLOBAL max_connections = 300;' -u${{ env.MYSQL_DB_USER }} -p${{ env.MYSQL_DB_PASSWORD }} | |
- name: Start PostgreSQL on Ubuntu | |
run: | | |
sudo systemctl start postgresql.service | |
pg_isready | |
- name: Setup PostgreSQL for ava tests | |
run: | | |
sudo -u postgres psql --command="alter system set max_connections = 300;" | |
sudo -u postgres psql --command="CREATE DATABASE keyv_test;" | |
sudo -u postgres psql --command="ALTER ROLE postgres WITH PASSWORD 'postgres';" --command="\du" | |
sudo systemctl restart postgresql.service | |
pg_isready | |
- name: Setup PNPM | |
uses: pnpm/action-setup@v2 | |
with: | |
version: latest | |
run_install: true | |
- run: pnpm test | |
- name: Report | |
run: mkdir -p coverage && npx c8 report --reporter=text-lcov > coverage/lcov.info | |
- name: Coverage | |
uses: coverallsapp/github-action@main | |
with: | |
github-token: ${{ secrets.GITHUB_TOKEN }} |