-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #17 from cdent/skip-or-fail-feature
Add support for skipping or expecting failure on a test
- Loading branch information
Showing
7 changed files
with
62 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
# | ||
# Tests to confirm that xfail and skip are working. | ||
# | ||
|
||
tests: | ||
|
||
- name: wrong status | ||
xfail: True | ||
url: / | ||
status: 404 | ||
|
||
- name: skip me | ||
skip: Skipping for now because we can't do it | ||
url: http://nowhere.example.com/house |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
pbr>=0.6,!=0.7,<1.0 | ||
six>=1.7.0 | ||
testtools | ||
PyYAML | ||
httplib2 | ||
jsonpath-rw | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
#!/bin/bash | ||
# Run the tests and confirm that the stuff we expect to skip or fail | ||
# does. | ||
|
||
GREP_FAIL_MATCH='expected failures=1' | ||
GREP_SKIP_MATCH='skips=1' | ||
|
||
python setup.py testr && \ | ||
testr last --subunit | subunit2pyunit 2>&1 | \ | ||
grep "${GREP_FAIL_MATCH}" && \ | ||
testr last | grep "${GREP_SKIP_MATCH}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters