Skip to content

Commit

Permalink
Adding pypytest example and workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
growlf authored Dec 30, 2023
1 parent 77fda5b commit d47481a
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 2 deletions.
14 changes: 12 additions & 2 deletions .github/workflows/python-app.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,20 @@
name: Python application

on:
schedule:
- cron: '0 1 * * 1'
release:
types: [published]
push:
branches: [ "main" ]
branches:
- main
- release/*
tags: [ 'v*.*.*' ]
pull_request:
branches: [ "main" ]
workflow_dispatch:



permissions:
contents: read
Expand Down Expand Up @@ -36,4 +46,4 @@ jobs:
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- name: Test with pytest
run: |
pytest
pytest -v --color=yes --cov=src --cov-report=xml tests/
8 changes: 8 additions & 0 deletions tests/baseline.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# test_with_pytest.py

def test_always_passes():
assert True

def test_always_fails():
assert False

0 comments on commit d47481a

Please sign in to comment.