Skip to content

🔨Testing Prettier #64

🔨Testing Prettier

🔨Testing Prettier #64

Workflow file for this run

name: Test Coveralls
on:
- push
- pull_request
jobs:
build_backend:
name: Build Backend
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js 20.x
uses: actions/setup-node@v3
with:
node-version: 20.x
- name: Install backend dependencies
run: |
cd Backend
npm install
npm install --save-dev babel-plugin-istanbul
npm install -g coveralls
- name: Run backend tests with coverage
run: |
cd Backend
npm run test:cov
- name: Upload backend coverage to Coveralls
uses: coverallsapp/github-action@v2
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
path-to-lcov: Backend/coverage/lcov.info
build_frontend:
name: Build Frontend
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js 20.x
uses: actions/setup-node@v3
with:
node-version: 20.x
- name: Install frontend dependencies
run: |
cd Frontend
npm install
npm install --save-dev babel-plugin-istanbul
npm install -g coveralls
- name: Run frontend tests with coverage
run: |
cd Frontend
npm run test:coverage
- name: Upload frontend coverage to Coveralls
uses: coverallsapp/github-action@v2
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
path-to-lcov: Frontend/coverage/lcov.info
debug:
name: Debug Workspace
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Debug Backend Workspace
run: |
echo "Listing files in Backend directory:"
ls -la Backend
echo "Displaying package.json in Backend directory:"
cat Backend/package.json
- name: Debug Frontend Workspace
run: |
echo "Listing files in Frontend directory:"
ls -la Frontend
echo "Displaying package.json in Frontend directory:"
cat Frontend/package.json
upload_results:
name: Upload Test Results
if: failure()
runs-on: ubuntu-latest
steps:
- uses: actions/upload-artifact@v2
with:
name: backend-test-results
path: Backend/coverage
- uses: actions/upload-artifact@v2
with:
name: frontend-test-results
path: Frontend/coverage