diff --git a/.github/workflows/actions.yml b/.github/workflows/actions.yml index 505454c..3700921 100644 --- a/.github/workflows/actions.yml +++ b/.github/workflows/actions.yml @@ -12,20 +12,6 @@ jobs: build: runs-on: ubuntu-latest - services: - mysql: - image: mysql:5.7 - env: - MYSQL_ROOT_PASSWORD: ${{ secrets.DB_PASSWORD }} - MYSQL_DATABASE: ${{ secrets.DB_NAME }} - ports: - - 3306:3306 - options: > - --health-cmd="mysqladmin ping --silent" - --health-interval=10s - --health-timeout=5s - --health-retries=3 - strategy: matrix: node-version: [20.x] @@ -42,28 +28,12 @@ jobs: - name: Install dependencies run: npm install - # Wait for the MySQL service to be ready - - name: Wait for MySQL to be ready - run: | - for i in {1..30}; do - if mysqladmin ping -h "127.0.0.1" --silent; then - break - fi - sleep 1 - done - - name: Run tests - env: - DB_NAME: ${{ secrets.DB_NAME }} - DB_USER: ${{ secrets.DB_USER }} - DB_PASSWORD: ${{ secrets.DB_PASSWORD }} - DB_HOST: 127.0.0.1 - DB_PORT: 3306 - run: npm test + run: | + npm test -- --ci --reporters="default" --reporters="jest-silent-reporter" + continue-on-error: true - - name: Upload Jest Test Report - if: always() - uses: actions/upload-artifact@v3 - with: - name: jest-test-report - path: ./coverage/ + - name: Display test case summary + run: | + echo "Test Summary:" + npm test -- --ci --reporters="jest-summary-reporter"