-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fixup! chore(ci): set up Lighthouse auditing in CI
- Loading branch information
Showing
2 changed files
with
26 additions
and
9 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,15 +16,11 @@ jobs: | |
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v2 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: 18 | ||
- name: Install Dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install -r requirements-test.txt | ||
sudo apt-get install -y gettext | ||
npm install -g @lhci/[email protected] | ||
- name: Run linting tools | ||
run: | | ||
cd app/ | ||
|
@@ -59,9 +55,29 @@ jobs: | |
run: | | ||
cd app/ | ||
python manage.py check | ||
- name: Run Lighthouse | ||
lighthouse: | ||
runs-on: ubuntu-latest # operating system your code will run on | ||
services: | ||
postgres: | ||
image: postgres:16 | ||
env: | ||
POSTGRES_USER: sadilar | ||
POSTGRES_PASSWORD: sadilar | ||
POSTGRES_DB: test_db_1 | ||
ports: | ||
- 5432:5432 | ||
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 | ||
steps: | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: 18 | ||
- name: Install Dependencies | ||
run: | | ||
cd app/ | ||
DB_NAME=test_db_1 DB_USER=sadilar DB_PASSWORD=sadilar python manage.py migrate | ||
echo done migrations | ||
lhci autorun | ||
python -m pip install --upgrade pip | ||
pip install -r requirements-test.txt | ||
sudo apt-get install -y gettext | ||
npm install -g @lhci/[email protected] | ||
- name: Migrate database | ||
run: cd app && DB_NAME=test_db_1 DB_USER=sadilar DB_PASSWORD=sadilar python manage.py migrate | ||
- name: Run Lighthouse | ||
run: cd app && lhci autorun |
This file contains 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