Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
63 changes: 18 additions & 45 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,21 +37,20 @@ jobs:
env:
OPENAI_API_KEY: "sk-fake-test-key-123"

- name: Coveralls Parallel
- name: Generate coverage report
run: |
poetry run coveralls
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COVERALLS_SERVICE_NAME: "github-actions"
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
COVERALLS_FLAG_NAME: django-coverage-${{ matrix.python-version }}
COVERALLS_PARALLEL: true
poetry run coverage xml

- name: Upload coverage to Codecov
uses: codecov/codecov-action@af09b5e394c93991b95a5e7646aeb90c1917f78f # v5.5.1
with:
files: ./coverage.xml
flags: backend-python-${{ matrix.python-version }}
name: backend-python-${{ matrix.python-version }}
token: ${{ secrets.CODECOV_TOKEN }}

build-frontend:
name: Frontend CI
# Wait for Django to finish before starting due to Coveralls parallel
# Source: https://docs.coveralls.io/parallel-builds
needs: build-django

runs-on: ubuntu-latest

Expand Down Expand Up @@ -83,40 +82,14 @@ jobs:
- name: Run tests
working-directory: ./frontend
run: |
pnpm run coveralls
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COVERALLS_SERVICE_NAME: "github-actions"
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
COVERALLS_FLAG_NAME: node-coverage
COVERALLS_PARALLEL: true

- name: Coveralls Parallel
uses: coverallsapp/github-action@v2
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
parallel: true
flag-name: node-coverage
allow-empty: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COVERALLS_SERVICE_NAME: "github-actions"
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
COVERALLS_FLAG_NAME: node-coverage
COVERALLS_PARALLEL: true
pnpm run coverage

coveralls:
name: Coveralls

# Wait for Django and Frontend to finish before starting due to Coveralls parallel
needs: [build-django, build-frontend]
- name: Upload frontend coverage to Codecov
uses: codecov/codecov-action@af09b5e394c93991b95a5e7646aeb90c1917f78f # v5.5.1
with:
files: ./frontend/coverage/lcov.info
flags: frontend
name: frontend-coverage
token: ${{ secrets.CODECOV_TOKEN }}

runs-on: ubuntu-latest

steps:
- name: Coveralls Finished
uses: coverallsapp/github-action@v2
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
parallel-finished: true
carryforward: "django-coverage-3.10,django-coverage-3.11,django-coverage-3.12,django-coverage-3.13,node-coverage"
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[![CI](https://github.com/vintasoftware/django-ai-assistant/actions/workflows/ci.yml/badge.svg)](https://github.com/vintasoftware/django-ai-assistant/actions/workflows/ci.yml)
[![Coverage Status](https://coveralls.io/repos/github/vintasoftware/django-ai-assistant/badge.svg?branch=main)](https://coveralls.io/github/vintasoftware/django-ai-assistant?branch=main)
[![codecov](https://codecov.io/gh/vintasoftware/django-ai-assistant/branch/main/graph/badge.svg)](https://codecov.io/gh/vintasoftware/django-ai-assistant)
[![Discord Server](https://img.shields.io/discord/1260577482122203206)](https://discord.gg/mqdubnPb)

# django-ai-assistant
Expand Down
2 changes: 1 addition & 1 deletion frontend/README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[![CI](https://github.com/vintasoftware/django-ai-assistant/actions/workflows/ci.yml/badge.svg)](https://github.com/vintasoftware/django-ai-assistant/actions/workflows/ci.yml)
[![Coverage Status](https://coveralls.io/repos/github/vintasoftware/django-ai-assistant/badge.svg?branch=main)](https://coveralls.io/github/vintasoftware/django-ai-assistant?branch=main)
[![codecov](https://codecov.io/gh/vintasoftware/django-ai-assistant/branch/main/graph/badge.svg)](https://codecov.io/gh/vintasoftware/django-ai-assistant)

# django-ai-assistant-client

Expand Down
3 changes: 1 addition & 2 deletions frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"test": "jest",
"test:cov": "jest --coverage",
"test:watch": "jest --watch",
"coveralls": "jest --coverage && cat ./coverage/lcov.info | coveralls",
"coverage": "jest --coverage",
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
"tsc": "tsc",
"generate-client": "openapi-ts"
Expand All @@ -72,7 +72,6 @@
"@typescript-eslint/eslint-plugin": "^7.14.1",
"@typescript-eslint/parser": "^7.14.1",
"@vitejs/plugin-react": "^4.3.1",
"coveralls": "^3.1.1",
"eslint": "^8.57.0",
"eslint-plugin-react": "^7.34.3",
"eslint-plugin-react-hooks": "^4.6.2",
Expand Down
Loading
Loading