diff --git a/.github/workflows/continuous-monitoring.yml b/.github/workflows/continuous-monitoring.yml new file mode 100644 index 00000000..a8f60769 --- /dev/null +++ b/.github/workflows/continuous-monitoring.yml @@ -0,0 +1,19 @@ +name: Continuous monitoring of distribution channels +on: + workflow_dispatch: + schedule: + - cron: '0 */6 * * *' + +jobs: + smoke-tests: + name: Run smoke tests + runs-on: ubuntu-latest + steps: + - name: Checkout Repository + uses: actions/checkout@v2 + - uses: actions/setup-python@v2 + with: + python-version: '3.x' + - run: pip install tox + - name: Run smoke tests + run: tox -c tox-distributioncheck.ini diff --git a/.gitignore b/.gitignore index efd51b7e..b4e4ffd6 100644 --- a/.gitignore +++ b/.gitignore @@ -20,3 +20,5 @@ pip-selfcheck.json .coverage* htmlcov + +venv diff --git a/tests/distributioncheck/__init__.py b/tests/distributioncheck/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/tests/distributioncheck/test_sanity.py b/tests/distributioncheck/test_sanity.py new file mode 100644 index 00000000..398b4fdb --- /dev/null +++ b/tests/distributioncheck/test_sanity.py @@ -0,0 +1,5 @@ +from aws_xray_sdk.core.models.segment import Segment + +def test_create_segment(): + segment = Segment('test') + assert segment.name == 'test' diff --git a/tox-distributioncheck.ini b/tox-distributioncheck.ini new file mode 100644 index 00000000..24176478 --- /dev/null +++ b/tox-distributioncheck.ini @@ -0,0 +1,9 @@ +[tox] +skipsdist = true + +[testenv:distribution-check] +deps = + pytest > 5.2.0 + aws-xray-sdk +commands = + pytest tests/distributioncheck