Created
September 26, 2012 22:24
-
-
Save DamonOehlman/3791015 to your computer and use it in GitHub Desktop.
testrest yaml file fornat
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
opts: | |
baseUrl: http://localhost:3000 | |
tests: | |
- it: returns Hi for / | |
get: / | |
expect: | |
status: 2xx | |
body: Hi | |
- it: returns a 404 for /does-not-exist | |
get: /does-not-exist | |
expect: 404 | |
- it: returns valid JSON for /json-test | |
get: /json-test | |
expect: | |
status: 2xx | |
body: | |
first: Roger | |
last: Rabbit | |
- it: partial JSON tests are ok too | |
get: /json-test | |
expect: | |
status: 2xx | |
body: | |
first: Roger | |
- it: expects the contents of empty to be an empty array | |
get: /empty | |
expect: | |
status: 2xx | |
body-match: "[]" | |
- it: expects that we can compare contents against a file | |
get: /test.txt | |
expect: | |
status: 2xx | |
body-match: "data/text.txt" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment