mirror of
https://git.sr.ht/~tsileo/microblog.pub
synced 2024-11-15 03:04:28 +00:00
Start the test suite
This commit is contained in:
parent
1c1816e102
commit
a138bc0c48
2 changed files with 10 additions and 3 deletions
|
@ -8,11 +8,11 @@ install:
|
||||||
- sudo curl -L https://github.com/docker/compose/releases/download/1.21.2/docker-compose-$(uname -s)-$(uname -m) -o /usr/local/bin/docker-compose
|
- sudo curl -L https://github.com/docker/compose/releases/download/1.21.2/docker-compose-$(uname -s)-$(uname -m) -o /usr/local/bin/docker-compose
|
||||||
- sudo chmod +x /usr/local/bin/docker-compose
|
- sudo chmod +x /usr/local/bin/docker-compose
|
||||||
- docker-compose --version
|
- docker-compose --version
|
||||||
- pip install pytest mypy flake8
|
- pip install -r dev-requirements.txt
|
||||||
script:
|
script:
|
||||||
- mypy --ignore-missing-imports .
|
- mypy --ignore-missing-imports .
|
||||||
|
# - flake8
|
||||||
- cp -r tests/me.yml config/me.yml
|
- cp -r tests/me.yml config/me.yml
|
||||||
- docker-compose up -d
|
- docker-compose up -d
|
||||||
- docker-compose ps
|
- docker-compose ps
|
||||||
# - flake8
|
- pytest -v --ignore data
|
||||||
# - pytest -v
|
|
||||||
|
|
7
tests/integration_test.py
Normal file
7
tests/integration_test.py
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
import requests
|
||||||
|
|
||||||
|
def test_ping_homepage():
|
||||||
|
"""Ensure the homepage is accessible."""
|
||||||
|
resp = requests.get('http://localhost:5005')
|
||||||
|
resp.raise_for_status()
|
||||||
|
assert 'ci@localhost' in resp.text
|
Loading…
Reference in a new issue