Skip to content

Commit

Permalink
Update CI/CD workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
Quiirex committed Jun 15, 2024
1 parent bb3f367 commit b599338
Showing 1 changed file with 50 additions and 20 deletions.
70 changes: 50 additions & 20 deletions .github/workflows/ci-cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,17 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v4

- name: Install dependencies
run: npm install
- name: Setup Node.js with node_modules cache
id: node-with-cache
uses: magnetikonline/action-node-modules-cache@v2
with:
node-version-file: .nvmrc
additional-cache-path: |
~/.cache/Cypress
- name: Install npm packages
if: steps.node-with-cache.outputs.cache-hit != 'true'
run: npm ci

- name: Run ESLint
run: npm run lint
Expand All @@ -34,8 +43,17 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v4

- name: Install dependencies
run: npm install
- name: Setup Node.js with node_modules cache
id: node-with-cache
uses: magnetikonline/action-node-modules-cache@v2
with:
node-version-file: .nvmrc
additional-cache-path: |
~/.cache/Cypress
- name: Install npm packages
if: steps.node-with-cache.outputs.cache-hit != 'true'
run: npm ci

- name: Build application
run: npm run build
Expand Down Expand Up @@ -73,6 +91,18 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v4

- name: Setup Node.js with node_modules cache
id: node-with-cache
uses: magnetikonline/action-node-modules-cache@v2
with:
node-version-file: .nvmrc
additional-cache-path: |
~/.cache/Cypress
- name: Install npm packages
if: steps.node-with-cache.outputs.cache-hit != 'true'
run: npm ci

- name: ZAP Full Scan
uses: zaproxy/action-full-scan@v0.10.0
with:
Expand All @@ -84,19 +114,19 @@ jobs:
name: security-testing-reports
path: security-testing-reports

performance-testing:
name: Performance Testing
runs-on: ubuntu-latest
needs: security-testing
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Run k6 tests
run: npm run performance

- name: Upload k6 performance reports
uses: actions/upload-artifact@v4
with:
name: performance-testing-reports
path: performance-testing-reports
# performance-testing:
# name: Performance Testing
# runs-on: ubuntu-latest
# needs: security-testing
# steps:
# - name: Checkout repository
# uses: actions/checkout@v4

# - name: Run k6 tests
# run: npm run performance

# - name: Upload k6 performance reports
# uses: actions/upload-artifact@v4
# with:
# name: performance-testing-reports
# path: performance-testing-reports

0 comments on commit b599338

Please sign in to comment.