Skip to content

Commit

Permalink
Setting pytest
Browse files Browse the repository at this point in the history
  • Loading branch information
AndreRico committed Oct 3, 2024
1 parent 8886727 commit 484cc89
Show file tree
Hide file tree
Showing 6 changed files with 52 additions and 1 deletion.
Binary file added .coverage
Binary file not shown.
37 changes: 37 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: CI

on:
push:
branches:
- development
pull_request:
branches:
- development

jobs:
test:
runs-on: ubuntu-latest

steps:
# Checkout the code
- name: Checkout code
uses: actions/checkout@v2

# Set up Python environment
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.10'

# Install dependencies
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install pytest
# Run the tests
- name: Run tests with pytest
run: |
pytest --maxfail=5 --disable-warnings
7 changes: 6 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
{
"python.analysis.typeCheckingMode": "basic"
"python.analysis.typeCheckingMode": "basic",
"python.testing.pytestArgs": [
"."
],
"python.testing.unittestEnabled": false,
"python.testing.pytestEnabled": true
}
4 changes: 4 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,14 +1,18 @@
apsw==3.46.1.0
black==24.8.0
click==8.1.7
exceptiongroup==1.2.2
flake8==7.1.1
iniconfig==2.0.0
mccabe==0.7.0
mypy-extensions==1.0.0
packaging==24.1
pathspec==0.12.1
platformdirs==4.3.6
pluggy==1.5.0
pycodestyle==2.12.1
pyflakes==3.2.0
pytest==8.3.3
sh==2.0.7
tomli==2.0.2
typing_extensions==4.12.2
Expand Down
Empty file added tests/__init__.py
Empty file.
5 changes: 5 additions & 0 deletions tests/test_start.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# tests/test_example.py


def test_example():
assert 1 + 1 == 2

0 comments on commit 484cc89

Please sign in to comment.