Skip to content

App group lifecycle plugin (#351) #1507

App group lifecycle plugin (#351)

App group lifecycle plugin (#351) #1507

Workflow file for this run

name: Test Python
on:
- push
- pull_request
jobs:
python-test:
runs-on: ubuntu-22.04
strategy:
matrix:
python-version: ["3.13"]
services:
postgres:
# Docker Hub image
image: postgres
# Provide the password for postgres
env:
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:
- uses: actions/checkout@v6
with:
persist-credentials: false
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install tox tox-gh-actions
- name: Test with tox
run: tox -e test
- name: Test with tox with postgresql
run: tox -e test-with-postgresql
- name: Test installing the notifications plugin
run: |
# Install the notifications plugin from examples/plugins/notifications
if [ -d "examples/plugins/notifications" ]; then
python -m pip install ./examples/plugins/notifications
else
echo "Notifications plugin directory not found; skipping installation"
fi
- name: Test installing the Slack notifications plugin
run: |
# Install the Slack notifications plugin from examples/plugins/notifications_slack
if [ -d "examples/plugins/notifications_slack" ]; then
python -m pip install ./examples/plugins/notifications_slack
else
echo "Slack notifications plugin directory not found; skipping installation"
fi
- name: Test installing the conditional access plugin
run: |
# Install the conditional access plugin from examples/plugins/conditional_access
if [ -d "examples/plugins/conditional_access" ]; then
python -m pip install ./examples/plugins/conditional_access
else
echo "Conditional access plugin directory not found; skipping installation"
fi
- name: Test installing the health check plugin
run: |
# Install the health check plugin from examples/plugins/health_check_plugin
if [ -d "examples/plugins/health_check_plugin" ]; then
python -m pip install ./examples/plugins/health_check_plugin
else
echo "Health check plugin directory not found; skipping installation"
fi
- name: Test installing the Datadog metrics reporter plugin
run: |
# Install the Datadog metrics reporter plugin from examples/plugins/datadog_metrics_reporter
if [ -d "examples/plugins/datadog_metrics_reporter" ]; then
python -m pip install ./examples/plugins/datadog_metrics_reporter
else
echo "Datadog metrics reporter plugin directory not found; skipping installation"
fi
- name: Test installing the app group lifecycle audit logger plugin
run: |
# Install the app group lifecycle audit logger plugin from examples/plugins/app_group_lifecycle_audit_logger
if [ -d "examples/plugins/app_group_lifecycle_audit_logger" ]; then
python -m pip install ./examples/plugins/app_group_lifecycle_audit_logger
else
echo "App group lifecycle audit logger plugin directory not found; skipping installation"
fi