Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: Test the examples code for the git lesson
on: push
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: 3.13.1
- name: Install dependencies
run: pip install -vv pytest
- name: Run test
run: pytest -v -s --color=yes test.py

2 changes: 2 additions & 0 deletions broken_python.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
def add_one(x : int) -> int:
return x + 2
5 changes: 5 additions & 0 deletions test.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@

def test_add_one():
from broken_python import add_one

assert add_one(1) == 2
Loading