Skip to content

feat support odmantic 1.x #12

feat support odmantic 1.x

feat support odmantic 1.x #12

name: Realworld Tests
on: [push]
jobs:
realworld-tests:
timeout-minutes: 10
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
with:
submodules: recursive
- name: Install poetry
run: pipx install poetry
- name: Set up Python 3.10
uses: actions/setup-python@v4
with:
python-version: "3.10"
cache: "poetry"
- name: Install dependencies
run: poetry install
- name: Start the MongoDB instance
uses: art049/mongodb-cluster-action@v0
id: mongodb-cluster-action
- name: Start the FastAPI server
run: |
./scripts/start.sh &
# Wait for the server
while ! curl "http://localhost:8000/health" > /dev/null 2>&1
do
sleep 1;
done
echo "Server ready."
env:
MONGO_URI: ${{ steps.mongodb-cluster-action.outputs.connection-string }}
- name: Run realworld backend tests
run: ./realworld/api/run-api-tests.sh
env:
APIURL: http://localhost:8000