ci and linting and such
change
commit 04aa35ca9b0260493418e38f1c83d9d4b420e615
author Alpha Chen <alpha@kejadlen.dev>
date
parent 54fc766f
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index b78a074..39aea54 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -14,10 +14,13 @@ jobs:
       - run: |
           python -m pip install --upgrade pip
           pip install -r dev-requirements.txt
-      - run: ruff --output-format=github .
+      - run: |
+          ruff check --output-format=github .
+          ruff format --check --output-format=github .
       - run: alembic upgrade head && alembic check
-      - run: make test
-      - run: coverage report
+      - run: |
+          coverage run -m pytest
+          coverage report
 
   build:
     runs-on: ubuntu-latest
diff --git a/Makefile b/Makefile
index f0cd2a4..bd37f7f 100644
--- a/Makefile
+++ b/Makefile
@@ -5,9 +5,16 @@ dev:
 	tailscale serve --bg 5000
 	fd ".*.(html|py)$$" | entr -r flask --app go_ji run --debug
 
+.PHONY: lint
+lint:
+	ruff check .
+	ruff format --check .
+	# alembic upgrade head && alembic check
+
 .PHONY: test
 test:
 	coverage run -m pytest
+	coverage report
 
 .PHONY: docker
 docker:
diff --git a/tests/test_go_ji.py b/tests/test_go_ji.py
index ac1790e..098b435 100644
--- a/tests/test_go_ji.py
+++ b/tests/test_go_ji.py
@@ -130,6 +130,7 @@ class TestGo:
 
             assert response.status_code == 404
 
+
 def test_die(authed, client):
     with authed:
         with pytest.raises(ZeroDivisionError):