Skip to content

Update version num #1515

Update version num

Update version num #1515

Workflow file for this run

name: Unit Tests
on: [ push ]
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
max-parallel: 4
matrix:
python-version: [ 3.8 ]
os: [ ubuntu-20.04 ]
steps:
- name: Checkout ${{ matrix.python-version }}
uses: actions/checkout@v2
with:
lfs: true
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
cd ..
git clone https://github.com/The-Academic-Observatory/observatory-platform.git
cd observatory-platform
pip install -e observatory-api
pip install -e observatory-platform
cd ..
cd academic-observatory-workflows
pip install -e .[tests]
- name: Check licenses
run: |
# stop the build if there are licensing issues
liccheck --sfile strategy.ini --rfile requirements.txt --level CAUTIOUS --reporting liccheck-output.txt --no-deps
- name: Lint with flake8
run: |
# stop the build if there are Python syntax errors or undefined names
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# 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: Run unit tests with coverage
env:
TEST_GCP_DATA_LOCATION: ${{ secrets.TEST_GCP_DATA_LOCATION }}
TEST_GCP_BUCKET_NAME: ${{ secrets.TEST_GCP_BUCKET_NAME }}
TEST_GCP_PROJECT_ID: ${{ secrets.TEST_GCP_PROJECT_ID }}
TEST_GCP_SERVICE_KEY: ${{ secrets.TEST_GCP_SERVICE_KEY }}
GOOGLE_APPLICATION_CREDENTIALS: /tmp/google_application_credentials.json
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: ${{ secrets.AWS_DEFAULT_REGION }}
AIRFLOW__CORE__LOAD_EXAMPLES: false
run: |
echo "${TEST_GCP_SERVICE_KEY}" | base64 --decode > /tmp/google_application_credentials.json
coverage run -m unittest discover -v
coverage xml
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
with:
file: ./coverage.xml
fail_ci_if_error: false