Skip to content

Commit

Permalink
fix(tests): Try installing packages before tests in testing pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
folland87 committed Nov 9, 2023
1 parent a344d77 commit 5940272
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
3 changes: 3 additions & 0 deletions .github/workflows/staging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ jobs:
steps:
- uses: actions/checkout@v3

- name : Install Packages
run : pip install -r requirements.txt

- name: test
run: python -m unittest

Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,8 @@ jobs:
steps:
- uses: actions/checkout@v3

- name : Install Packages
run : pip install -r requirements.txt

- name: test
run: python -m unittest
3 changes: 2 additions & 1 deletion tests/tests_services/test_lighthouse_calculator.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@ def test_get_lighthouse(self, mock_run):
)
wrapper = LighthouseCalculator()
result = wrapper.get_lighthouse(url="http://example.com")
self.assertEqual(result, {"score": 100})
self.assertEqual(
result, {"categories": {"accessibility": {"score": 100}}})

@patch("subprocess.run")
def test_get_lighthouse_error(self, mock_run):
Expand Down

0 comments on commit 5940272

Please sign in to comment.