Skip to content

Commit

Permalink
Try to pass AMDA credentials to doctest in GH Actions
Browse files Browse the repository at this point in the history
Signed-off-by: Alexis Jeandet <alexis.jeandet@member.fsf.org>
  • Loading branch information
jeandet committed Jan 24, 2022
1 parent 69aa198 commit e866dd9
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 8 deletions.
9 changes: 5 additions & 4 deletions .github/workflows/PRs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@ name: PR Tests
on: [pull_request]

jobs:
env:
SPEASY_AMDA_USERNAME: ${{ secrets.SPEASY_AMDA_USERNAME }}
SPEASY_AMDA_PASSWORD: ${{ secrets.SPEASY_AMDA_PASSWORD }}

build:

runs-on: ubuntu-latest
Expand Down Expand Up @@ -30,12 +34,9 @@ jobs:
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- name: Test with pytest
env:
SPEASY_AMDA_USERNAME: ${{ secrets.SPEASY_AMDA_USERNAME }}
SPEASY_AMDA_PASSWORD: ${{ secrets.SPEASY_AMDA_PASSWORD }}
run: |
pip install pytest pytest-cov sphinx numpydoc sphinx-rtd-theme
SPEASY_AMDA_PASSWORD="${{ secrets.SPEASY_AMDA_PASSWORD }}" SPEASY_AMDA_USERNAME="${{ secrets.SPEASY_AMDA_USERNAME }}" pytest --cov=./ --cov-report=xml
pytest --cov=./ --cov-report=xml
make doctest
- name: Upload coverage to Codecov
if: matrix.python-version == '3.8'
Expand Down
9 changes: 5 additions & 4 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@ name: Tests
on: [push]

jobs:
env:
SPEASY_AMDA_USERNAME: ${{ secrets.SPEASY_AMDA_USERNAME }}
SPEASY_AMDA_PASSWORD: ${{ secrets.SPEASY_AMDA_PASSWORD }}

build:

runs-on: ubuntu-latest
Expand Down Expand Up @@ -30,12 +34,9 @@ jobs:
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- name: Test with pytest
env:
SPEASY_AMDA_USERNAME: ${{ secrets.SPEASY_AMDA_USERNAME }}
SPEASY_AMDA_PASSWORD: ${{ secrets.SPEASY_AMDA_PASSWORD }}
run: |
pip install pytest pytest-cov sphinx numpydoc sphinx-rtd-theme
SPEASY_AMDA_PASSWORD="${{ secrets.SPEASY_AMDA_PASSWORD }}" SPEASY_AMDA_USERNAME="${{ secrets.SPEASY_AMDA_USERNAME }}" pytest --cov=./ --cov-report=xml
pytest --cov=./ --cov-report=xml
make doctest
- name: Upload coverage to Codecov
if: matrix.python-version == '3.8'
Expand Down

0 comments on commit e866dd9

Please sign in to comment.