Skip to content

Integration tests

Integration tests #1

name: Integration tests
run-name: Integration tests
on: [push]
jobs:
integration-test:
runs-on: ubuntu-latest
steps:
- run: echo "Executing Integration tests"
- run: echo "🐧 This job is now running on a ${{ runner.os }} server hosted by GitHub!"
- run: echo "🔎 The name of your branch is ${{ github.ref }} and your repository is ${{ github.repository }}."
- name: Check out repository code
uses: actions/checkout@v4
- run: echo "💡 The ${{ github.repository }} repository has been cloned to the runner."
- uses: browser-actions/setup-chrome@v1
- run: chrome --version
- run: echo "🖥️ The workflow is now ready to test your code on the runner."
- name: "Create python environment"
run: |
python3 -m venv calibre-web-env
source calibre-web-env/bin/activate
- name: Install Python dependencies for testing
uses: py-actions/py-dependency-install@v4
with:
path: "requirements.txt"
- name: "Download dummy database"
run: |
wget -O app.db "https://github.com/iiab/iiab/raw/refs/heads/master/roles/calibre-web/files/app.db"
- name: "Debugging line"
run: |
ls -la
- name: "Execute calibre web in background"
run: |
nohup python3 cps.py &
- name: "Verify local website"
run: |
curl -L localhost:8083
- name: Install Python dependencies for testing
uses: py-actions/py-dependency-install@v4
with:
path: "integration-tests-requirements.txt"
- name: Execute PyTest for Integration Tests
run: |
HEADLESS=true pytest -s