Skip to content

arch(core): add sop table/update task prompts #30

arch(core): add sop table/update task prompts

arch(core): add sop table/update task prompts #30

Workflow file for this run

name: core-test
on:
push:
branches:
- main
- dev
paths:
- 'src/server/core/**'
- '.github/workflows/core-test.yaml'
pull_request:
branches:
- main
- dev
paths:
- 'src/server/core/**'
- '.github/workflows/core-test.yaml'
jobs:
test:
name: Tests on ${{ matrix.os }} for ${{ matrix.python-version }}
strategy:
matrix:
python-version: [3.13]
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}
permissions:
contents: read
defaults:
run:
working-directory: src/server/
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v6
- name: Set up Python
run: uv python install
- name: Install dependencies
run: |
cd core
uv sync --frozen --no-dev --no-cache-dir
- name: Start containers
run: |
cp .env.example .env
cp core/config.yaml.example core/config.yaml
sh scripts/local_dev_deps.sh &
- name: Wait for containers to start
working-directory: ./src/server
run: |
set -a; . ./.env; set +a
until docker compose exec acontext-server-pg pg_isready -U $DATABASE_USER -d $DATABASE_NAME; do
echo "Waiting for PostgreSQL to be ready..."
sleep 5
done
until docker compose exec acontext-server-minio curl -f http://127.0.0.1:9000/minio/health/ready; do
echo "Waiting for MinIO to be ready..."
sleep 5
done
docker compose exec acontext-server-minio mc alias set local http://127.0.0.1:9000 $S3_ACCESS_KEY $S3_SECRET_KEY
until docker compose exec acontext-server-minio mc ls local/$S3_BUCKET >/dev/null 2>&1; do
echo "Waiting for S3 bucket '$S3_BUCKET' to be created..."
sleep 5
done
- name: Test with pytest
run: |
cd core
uv run -m pytest --junit-xml=junit/test-results-${{ matrix.python-version }}.xml --cov=. --cov-report=xml:coverage-${{ matrix.python-version }}.xml tests/ -s -v
- name: Upload pytest test results and coverage
uses: actions/upload-artifact@v4
with:
name: pytest-results-${{ matrix.python-version }}
path: |
./src/server/core/junit/test-results-${{ matrix.python-version }}.xml
./src/server/core/coverage-${{ matrix.python-version }}.xml
if: ${{ always() }}
- name: Stop containers
if: ${{ always() }}
run: |
docker compose down