Skip to content

build(deps): bump faker from 33.1.0 to 33.1.2 #2019

build(deps): bump faker from 33.1.0 to 33.1.2

build(deps): bump faker from 33.1.0 to 33.1.2 #2019

Workflow file for this run

name: CI
on:
push:
branches: [ main, dev, dependabot/dev ]
pull_request:
branches: [ main, dev, dependabot/dev ]
jobs:
test:
runs-on: ubuntu-latest
services:
db_service:
image: postgres
env:
POSTGRES_USER: postgres
POSTGRES_DB: uobtheatre_api
POSTGRES_PASSWORD: postgres
# Set health checks to wait until postgres has started
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
# Maps tcp port 5432 on service container to the host
- 5432:5432
steps:
# Set up cache for pip packages
- name: Cache pip packages πŸ“¦
uses: actions/cache@v4
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
- name: Checkout πŸ›Ž
uses: actions/checkout@master
# Setup python
- name: Setup python 3.10 env πŸ—
uses: actions/setup-python@v5
with:
python-version: "3.10"
# Install dependencies
- name: Install dependencies πŸ‘¨πŸ»β€πŸ’»
run: pip install -r requirements/local.txt
# Collect static
- name: Collect Static πŸ“¦
run: ./manage.py collectstatic --noinput
- name: Run tests πŸ§ͺ
run: |
pytest --cov uobtheatre --cov-fail-under 100 -m "not system_test"
env:
DATABASE_URL: postgresql://postgres:[email protected]:5432/uobtheatre_api
- name: Run system tests β€πŸ”¬
if: ${{ github.actor != 'dependabot[bot]' }}
run: |
pytest --cov uobtheatre -m "system_test"
env:
DATABASE_URL: postgresql://postgres:[email protected]:5432/uobtheatre_api
SQUARE_ACCESS_TOKEN: ${{ secrets.SQUARE_SANDBOX_ACCESS_TOKEN }}
lint:
runs-on: ubuntu-latest
steps:
# Set up cache for pip packages
- name: Cache pip packages πŸ“¦
uses: actions/cache@v4
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
- name: Checkout πŸ›Ž
uses: actions/checkout@master
# Setup python
- name: Setup python 3.10 env πŸ—
uses: actions/setup-python@v5
with:
python-version: "3.10"
# Install dependencies
- name: Install dependencies πŸ‘¨πŸ»β€πŸ’»
run: pip install -r requirements/local.txt
- name: Run black - formatting
run: |
black uobtheatre --check
- name: Run isort - sort imports
run: |
isort uobtheatre -c
- name: Run pylint - linting
run: |
pylint uobtheatre
- name: Run mypy - static type checking
run: |
mypy uobtheatre
# Check migrations have been made
- name: Ensure migrations have been generated πŸ‘€
run: python manage.py makemigrations --check
fixtures:
runs-on: ubuntu-latest
services:
db_service:
image: postgres
env:
POSTGRES_USER: postgres
POSTGRES_DB: uobtheatre_api
POSTGRES_PASSWORD: postgres
# Set health checks to wait until postgres has started
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
# Maps tcp port 5432 on service container to the host
- 5432:5432
steps:
# Set up cache for pip packages
- name: Cache pip packages πŸ“¦
uses: actions/cache@v4
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
- name: Checkout πŸ›Ž
uses: actions/checkout@master
# Setup python
- name: Setup python 3.10 env πŸ—
uses: actions/setup-python@v5
with:
python-version: "3.10"
# Install dependencies
- name: Install dependencies πŸ‘¨πŸ»β€πŸ’»
run: pip install -r requirements/local.txt
# Collect static
- name: Collect Static πŸ“¦
run: ./manage.py collectstatic --noinput
- name: Check example fixture data can still be loaded πŸ”„
run: |
./manage.py migrate
./manage.py loaddata uobtheatre/images/fixtures.json uobtheatre/addresses/fixtures.json uobtheatre/users/fixtures.json uobtheatre/venues/fixtures.json uobtheatre/societies/fixtures.json uobtheatre/productions/fixtures.json uobtheatre/bookings/fixtures.json
env:
DATABASE_URL: postgresql://postgres:[email protected]:5432/uobtheatre_api
- name: Check e2e fixture data can still be loaded πŸ”„
run: |
./manage.py flush --no-input
./manage.py loaddata db.json
env:
DATABASE_URL: postgresql://postgres:[email protected]:5432/uobtheatre_api
schema:
runs-on: ubuntu-latest
steps:
# Set up cache for pip packages
- name: Cache pip packages πŸ“¦
uses: actions/cache@v4
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
- name: Checkout πŸ›Ž
uses: actions/checkout@master
# Setup python
- name: Setup python 3.10 env πŸ—
uses: actions/setup-python@v5
with:
python-version: "3.10"
# Install dependencies
- name: Install dependencies πŸ‘¨πŸ»β€πŸ’»
run: pip install -r requirements/local.txt
# Generate schmea
- name: Generate schema πŸ€–
run: |
./manage.py graphql_schema --schema uobtheatre.schema.schema --out schema.graphql
# Push up the schema
- name: Commit schema πŸ•Έ
uses: EndBug/add-and-commit@v9
with:
message: 'Updated schema'
author_name: github-actions
author_email: 41898282+github-actions[bot]@users.noreply.github.com