-
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.
- Loading branch information
1 parent
127304d
commit 3b2e1e5
Showing
1 changed file
with
36 additions
and
18 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 |
---|---|---|
|
@@ -9,16 +9,33 @@ jobs: | |
Linting: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Fetch base and install Poetry | ||
run: | | ||
git fetch origin ${{github.base_ref}} | ||
pipx install poetry | ||
- name: Setup Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: 3.11 | ||
python-version: "3.11" | ||
cache: "poetry" | ||
|
||
- name: Install Python Packages | ||
run: | | ||
cd devops | ||
poetry install --only dev | ||
- name: Run flake8 | ||
run: poetry run flake8 geoapi | ||
run: | | ||
cd devops | ||
poetry run flake8 ../geoapi | ||
- name: Formatting with black | ||
run: | | ||
poetry run black --check geoapi | ||
cd devops | ||
poetry run black --check ../geoapi | ||
Geoapi_Unit_Tests: | ||
runs-on: ubuntu-latest | ||
|
@@ -40,38 +57,39 @@ jobs: | |
--health-timeout 5s | ||
--health-retries 5 | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Fetch base and install Poetry | ||
run: | | ||
git fetch origin ${{github.base_ref}} | ||
pipx install poetry | ||
- name: Setup Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: 3.11 | ||
python-version: "3.11" | ||
cache: "poetry" | ||
|
||
- name: Install ffmpeg | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y ffmpeg | ||
- name: Setup Poetry | ||
uses: abatilo/[email protected] | ||
with: | ||
poetry-version: 1.8.3 | ||
- uses: actions/cache@v1 | ||
with: | ||
path: ~/.cache/pypoetry/virtualenvs | ||
key: ${{ runner.os }}-poetry-${{ hashFiles('**/poetry.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-poetry- | ||
- name: Install Python Packages | ||
run: | | ||
cd devops | ||
poetry install --with dev,flask,worker | ||
- name: Run server-side unit tests | ||
run: | | ||
cd devops | ||
poetry run pytest ../geoapi | ||
Workers_Unit_Tests: | ||
runs-on: ubuntu-latest | ||
services: | ||
postgres: | ||
image: mdillon/postgis:11-alpine | ||
image: postgis/postgis:11-3.0-alpine | ||
env: | ||
POSTGRES_USER: dev | ||
POSTGRES_PASSWORD: dev | ||
|
@@ -84,7 +102,7 @@ jobs: | |
--health-timeout 5s | ||
--health-retries 5 | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/checkout@v4 | ||
- uses: docker/login-action@v1 | ||
with: | ||
password: ${{ secrets.DOCKER_PASSWORD }} | ||
|