refactor(faculty): remove unused Apply Leave and Free Slot Enquiry co… #101
This file contains hidden or 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: CI - Automated Team Testing | |
| on: | |
| push: | |
| branches: ["master"] | |
| pull_request: | |
| branches: ["master"] | |
| jobs: | |
| # ───────────────────────────────────────────── | |
| # Backend CI — lint, unit tests, integration tests | |
| # ───────────────────────────────────────────── | |
| backend: | |
| name: Backend Tests | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| cache: npm | |
| cache-dependency-path: backend/package-lock.json | |
| - name: Install backend dependencies | |
| working-directory: backend | |
| run: npm ci | |
| - name: Lint backend | |
| working-directory: backend | |
| run: npx eslint . || echo "Lint warnings found" | |
| - name: Run backend tests | |
| working-directory: backend | |
| continue-on-error: true | |
| run: npm test -- --verbose | |
| # ───────────────────────────────────────────── | |
| # Frontend CI — lint, unit tests, build | |
| # ───────────────────────────────────────────── | |
| frontend: | |
| name: Frontend Build & Test | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| cache: npm | |
| cache-dependency-path: frontend/package-lock.json | |
| - name: Install frontend dependencies | |
| working-directory: frontend | |
| run: npm ci | |
| - name: Lint frontend | |
| working-directory: frontend | |
| run: npm run lint | |
| - name: Run frontend tests | |
| working-directory: frontend | |
| run: npm test | |
| - name: Build frontend | |
| working-directory: frontend | |
| run: npm run build | |
| # ───────────────────────────────────────────── | |
| # Deploy Frontend to Vercel (only on master push) | |
| # ───────────────────────────────────────────── | |
| deploy-frontend: | |
| name: Deploy Frontend | |
| needs: [frontend] | |
| if: github.event_name == 'push' && github.ref == 'refs/heads/master' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Deploy to Vercel | |
| uses: amondnet/vercel-action@v25 | |
| with: | |
| vercel-token: ${{ secrets.VERCEL_TOKEN }} | |
| vercel-org-id: ${{ secrets.VERCEL_ORG_ID }} | |
| vercel-project-id: ${{ secrets.VERCEL_PROJECT_ID }} | |
| vercel-args: '--prod' |