forked from aws/aws-dynamodb-encryption-python
-
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.
chore: fix all CI and start migration to GitHub Actions (aws#139)
* chore: force tox to update pip * chore: update isort configuration to 5.0.0 * chore: autoformat * chore: hypothesis.HealthCheck.hung_test is deprecated * chore: flake8 linting * chore: update pylint and flake8 configs * chore: linting fixes * chore: update default Python envlist - remove 3.4 - add 3.8 * chore: Python 2 lists do not have copy() * chore: address all pylint issues aside from TODO references * chore: unlock mypy version * chore: fix type annotation syntax errors * chore: move TODOs into GitHub issues * chore: move test TODOs to GitHub issues * chore: autoformat * chore: rework moto use - fixes issues with multiple service mocks in Python 2 - module scope avoids resetting the mocked service for tests that use multiple mocked tables * chore: force nocmk environment to black all environment variables * chore: add GitHub Actions workflows * chore: move sourcebuildcheck and nocmk into upstream-py3 job * chore: add ci-requirements.txt * chore: work around bug in Python 2 Hypothesis behavior by only running fast tests for Python 2 * chore: fix sourcebuildcheck script - The ls command was getting a relative path when the script ran but a bare filename in manual checks. * chore: pruning known runs from Travis that fail due to known infrastructure issues
- Loading branch information
1 parent
1d24752
commit 27bb2c0
Showing
51 changed files
with
473 additions
and
224 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 |
---|---|---|
@@ -0,0 +1,44 @@ | ||
# This workflow runs static analysis checks on pull requests. | ||
name: static analysis | ||
|
||
on: | ||
pull_request: | ||
push: | ||
# Run once a day | ||
schedule: | ||
- cron: '0 0 * * *' | ||
|
||
jobs: | ||
analysis: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
category: | ||
# Disabled pending completion of integration | ||
# https://github.com/aws/aws-dynamodb-encryption-python/issues/66 | ||
# - mypy-py2 | ||
# - mypy-py3 | ||
- bandit | ||
- doc8 | ||
- readme | ||
- docs | ||
- flake8 | ||
- pylint | ||
- flake8-tests | ||
- flake8-examples | ||
- pylint-tests | ||
- pylint-examples | ||
- black-check | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v1 | ||
with: | ||
python-version: 3.x | ||
- run: | | ||
python -m pip install --upgrade pip | ||
pip install --upgrade -r ci-requirements.txt | ||
- name: check | ||
env: | ||
TOXENV: ${{ matrix.category }} | ||
run: tox -- -vv |
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 |
---|---|---|
@@ -0,0 +1,131 @@ | ||
# This workflow runs tests on pull requests. | ||
name: tests | ||
|
||
on: | ||
pull_request: | ||
push: | ||
# Run once a day | ||
schedule: | ||
- cron: '0 0 * * *' | ||
|
||
jobs: | ||
# Hypothesis no longer supports Python 2 and | ||
# there is a bug that appears with our slow tests | ||
# only on Python 2. | ||
# Until we also drop Python 2 support, | ||
# the workaround is just that we don't run the slow tests | ||
# on Python 2. | ||
py2-tests: | ||
runs-on: ${{ matrix.platform.os }} | ||
strategy: | ||
fail-fast: true | ||
matrix: | ||
platform: | ||
- os: ubuntu-latest | ||
architecture: x64 | ||
- os: windows-latest | ||
architecture: x64 | ||
# x86 builds are only meaningful for Windows | ||
- os: windows-latest | ||
architecture: x86 | ||
- os: macos-latest | ||
architecture: x64 | ||
category: | ||
- local-fast | ||
# These require credentials. | ||
# Enable them once we sort how to provide them. | ||
# - integ-fast | ||
# - examples | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v1 | ||
with: | ||
python-version: 2.7 | ||
architecture: ${{ matrix.platform.architecture }} | ||
- run: | | ||
python -m pip install --upgrade pip | ||
pip install --upgrade -r ci-requirements.txt | ||
- name: run test | ||
env: | ||
TOXENV: ${{ matrix.category }} | ||
run: tox -- -vv | ||
tests: | ||
runs-on: ${{ matrix.platform.os }} | ||
strategy: | ||
fail-fast: true | ||
matrix: | ||
platform: | ||
- os: ubuntu-latest | ||
architecture: x64 | ||
- os: windows-latest | ||
architecture: x64 | ||
# x86 builds are only meaningful for Windows | ||
- os: windows-latest | ||
architecture: x86 | ||
- os: macos-latest | ||
architecture: x64 | ||
python: | ||
- 3.5 | ||
- 3.6 | ||
- 3.7 | ||
- 3.8 | ||
- 3.x | ||
category: | ||
- local-slow | ||
# These require credentials. | ||
# Enable them once we sort how to provide them. | ||
# - integ-slow | ||
# - examples | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v1 | ||
with: | ||
python-version: ${{ matrix.python }} | ||
architecture: ${{ matrix.platform.architecture }} | ||
- run: | | ||
python -m pip install --upgrade pip | ||
pip install --upgrade -r ci-requirements.txt | ||
- name: run test | ||
env: | ||
TOXENV: ${{ matrix.category }} | ||
run: tox -- -vv | ||
upstream-py3: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: true | ||
matrix: | ||
category: | ||
- nocmk | ||
- sourcebuildcheck | ||
- test-upstream-requirements-py37 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v1 | ||
with: | ||
python-version: 3.7 | ||
- run: | | ||
python -m pip install --upgrade pip | ||
pip install --upgrade -r ci-requirements.txt | ||
- name: run test | ||
env: | ||
TOXENV: ${{ matrix.category }} | ||
run: tox -- -vv | ||
upstream-py2: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: true | ||
matrix: | ||
category: | ||
- test-upstream-requirements-py27 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v1 | ||
with: | ||
python-version: 2.7 | ||
- run: | | ||
python -m pip install --upgrade pip | ||
pip install --upgrade -r ci-requirements.txt | ||
- name: run test | ||
env: | ||
TOXENV: ${{ matrix.category }} | ||
run: tox -- -vv |
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
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
tox |
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
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
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
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
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
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
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
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
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
Oops, something went wrong.