-
Notifications
You must be signed in to change notification settings - Fork 323
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add integration tests to the test suite (#377)
* Add integration tests to the test suite
- Loading branch information
Showing
3 changed files
with
138 additions
and
19 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 |
---|---|---|
|
@@ -58,4 +58,47 @@ jobs: | |
- name: Test Dist Generation | ||
run: | | ||
python setup.py sdist bdist_wheel | ||
twine check dist/* | ||
twine check dist/* | ||
Integration: | ||
continue-on-error: true | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [macos-latest, windows-latest] | ||
python-version: [2.7, 3.5, 3.6, 3.7, 3.8, pypy2, pypy3] | ||
exclude: | ||
- os: windows-latest | ||
python-version: 3.6 | ||
include: | ||
- os: linux | ||
python-version: 3.4 | ||
steps: | ||
- uses: actions/[email protected] | ||
- name: Setup Python environment | ||
uses: actions/[email protected] | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Install Requirements | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install flake8 pytest | ||
pip install -r requirements.txt | ||
pip install -r test/requirements.txt | ||
python setup.py install | ||
- name: Run Integration Tests | ||
env: | ||
LEGACY_USER_DROPBOX_TOKEN: ${{ secrets.LEGACY_USER_DROPBOX_TOKEN }} | ||
LEGACY_USER_CLIENT_ID: ${{ secrets.LEGACY_USER_CLIENT_ID }} | ||
LEGACY_USER_CLIENT_SECRET: ${{ secrets.LEGACY_USER_CLIENT_SECRET }} | ||
LEGACY_USER_REFRESH_TOKEN: ${{ secrets.LEGACY_USER_REFRESH_TOKEN }} | ||
SCOPED_USER_DROPBOX_TOKEN: ${{ secrets.SCOPED_USER_DROPBOX_TOKEN }} | ||
SCOPED_USER_CLIENT_ID: ${{ secrets.SCOPED_USER_CLIENT_ID }} | ||
SCOPED_USER_CLIENT_SECRET: ${{ secrets.SCOPED_USER_CLIENT_SECRET }} | ||
SCOPED_USER_REFRESH_TOKEN: ${{ secrets.SCOPED_USER_REFRESH_TOKEN }} | ||
SCOPED_TEAM_DROPBOX_TOKEN: ${{ secrets.SCOPED_TEAM_DROPBOX_TOKEN }} | ||
SCOPED_TEAM_CLIENT_ID: ${{ secrets.SCOPED_TEAM_CLIENT_ID }} | ||
SCOPED_TEAM_CLIENT_SECRET: ${{ secrets.SCOPED_TEAM_CLIENT_SECRET }} | ||
SCOPED_TEAM_REFRESH_TOKEN: ${{ secrets.SCOPED_TEAM_REFRESH_TOKEN }} | ||
DROPBOX_SHARED_LINK: ${{ secrets.DROPBOX_SHARED_LINK }} | ||
run: | | ||
pytest test/integration/test_dropbox.py |
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 |
---|---|---|
|
@@ -31,4 +31,42 @@ jobs: | |
uses: codecov/[email protected] | ||
with: | ||
flags: unit | ||
fail_ci_if_error: true | ||
IntegrationCoverage: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Setup Python environment | ||
uses: actions/[email protected] | ||
with: | ||
python-version: '3.7' | ||
- name: Install Requirements | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install coverage pytest | ||
pip install -r requirements.txt | ||
pip install -r test/requirements.txt | ||
python setup.py install | ||
- name: Generate Unit Test Coverage | ||
env: | ||
LEGACY_USER_DROPBOX_TOKEN: ${{ secrets.LEGACY_USER_DROPBOX_TOKEN }} | ||
LEGACY_USER_CLIENT_ID: ${{ secrets.LEGACY_USER_CLIENT_ID }} | ||
LEGACY_USER_CLIENT_SECRET: ${{ secrets.LEGACY_USER_CLIENT_SECRET }} | ||
LEGACY_USER_REFRESH_TOKEN: ${{ secrets.LEGACY_USER_REFRESH_TOKEN }} | ||
SCOPED_USER_DROPBOX_TOKEN: ${{ secrets.SCOPED_USER_DROPBOX_TOKEN }} | ||
SCOPED_USER_CLIENT_ID: ${{ secrets.SCOPED_USER_CLIENT_ID }} | ||
SCOPED_USER_CLIENT_SECRET: ${{ secrets.SCOPED_USER_CLIENT_SECRET }} | ||
SCOPED_USER_REFRESH_TOKEN: ${{ secrets.SCOPED_USER_REFRESH_TOKEN }} | ||
SCOPED_TEAM_DROPBOX_TOKEN: ${{ secrets.SCOPED_TEAM_DROPBOX_TOKEN }} | ||
SCOPED_TEAM_CLIENT_ID: ${{ secrets.SCOPED_TEAM_CLIENT_ID }} | ||
SCOPED_TEAM_CLIENT_SECRET: ${{ secrets.SCOPED_TEAM_CLIENT_SECRET }} | ||
SCOPED_TEAM_REFRESH_TOKEN: ${{ secrets.SCOPED_TEAM_REFRESH_TOKEN }} | ||
DROPBOX_SHARED_LINK: ${{ secrets.DROPBOX_SHARED_LINK }} | ||
run: | | ||
coverage run --rcfile=.coveragerc -m pytest test/integration/test_dropbox.py | ||
coverage xml | ||
- name: Publish Coverage | ||
uses: codecov/[email protected] | ||
with: | ||
flags: integration | ||
fail_ci_if_error: true |
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