Skip to content
Merged
6 changes: 3 additions & 3 deletions .github/workflows/pre-commit.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
name: Pre-commit Checks

on:
push:
branches: [ main, master ]
pull_request:
branches: [ main, master ]

Expand All @@ -11,11 +9,13 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
with:
fetch-depth: 0

- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: '3.10'
python-version: '3.11'
cache: 'pip'

- name: Install dependencies
Expand Down
1 change: 1 addition & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@ repos:
hooks:
- id: black
language_version: python3.11
args: [--line-length=88]
16 changes: 16 additions & 0 deletions reports/TESTS-api.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<testsuite name="api.API Response Testing" tests="1" errors="0" failures="0" skipped="0" time="0.403732" timestamp="2026-04-20T03:17:09.238199" hostname="Mac.ts.net lan"><testcase classname="api.API Response Testing" name="Validate API response" status="passed" time="0.403732"><system-out>
<![CDATA[
@scenario.begin
Scenario: Validate API response
Given I make a request to the free API ... passed in 0.403s
When I receive the response ... passed in 0.000s
Then the response status should be 200 ... passed in 0.000s

@scenario.end
--------------------------------------------------------------------------------

Captured stdout:
200

]]>
</system-out></testcase></testsuite>
25 changes: 25 additions & 0 deletions reports/TESTS-e2e.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<testsuite name="e2e.Google Search Functionality" tests="1" errors="0" failures="1" skipped="0" time="3.245058" timestamp="2026-04-20T03:17:17.686014" hostname="Mac.ts.net lan"><testcase classname="e2e.Google Search Functionality" name="Search for a query on Google" status="failed" time="3.245058"><failure type="AssertionError" message="">
<![CDATA[
Failing step: Then I should see results for "Behave BDD" ... failed in 0.009s
Location: features/e2e.feature:9
Traceback (most recent call last):
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/behave/model.py", line 1329, in run
match.run(runner.context)
File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/behave/matchers.py", line 98, in run
self.func(context, *args, **kwargs)
File "features/steps/e2e.py", line 19, in step_see_results
assert query in results_element.get_attribute("innerText")
AssertionError
]]>
</failure><system-out>
<![CDATA[
@scenario.begin
Scenario: Search for a query on Google
Given I open the Google webpage ... passed in 0.993s
When I search for "Behave BDD" ... passed in 2.243s
Then I should see results for "Behave BDD" ... failed in 0.009s

@scenario.end
--------------------------------------------------------------------------------
]]>
</system-out></testcase></testsuite>
23 changes: 23 additions & 0 deletions reports/TESTS-unit.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<testsuite name="unit.Mocking and Utility Functions" tests="2" errors="0" failures="0" skipped="0" time="0.000376" timestamp="2026-04-20T03:17:10.079845" hostname="Mac.ts.net lan"><testcase classname="unit.Mocking and Utility Functions" name="Using a mock object" status="passed" time="0.000275"><system-out>
<![CDATA[
@scenario.begin
Scenario: Using a mock object
Given a mock object is created ... passed in 0.000s
When the mock object is called ... passed in 0.000s
Then it should return the expected result ... passed in 0.000s

@scenario.end
--------------------------------------------------------------------------------
]]>
</system-out></testcase><testcase classname="unit.Mocking and Utility Functions" name="Using a utility function" status="passed" time="0.000101"><system-out>
<![CDATA[
@scenario.begin
Scenario: Using a utility function
Given a utility function is available ... passed in 0.000s
When I call the utility function ... passed in 0.000s
Then it should return the correct output ... passed in 0.000s

@scenario.end
--------------------------------------------------------------------------------
]]>
</system-out></testcase></testsuite>