forked from bcgov/STRR
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
55 additions
and
530 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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,7 @@ | ||
[pytest] | ||
env = | ||
DATABASE_TEST_USERNAME=postgres | ||
DATABASE_TEST_PASSWORD=postgres | ||
DATABASE_TEST_NAME=test | ||
DATABASE_TEST_HOST=localhost | ||
DATABASE_TEST_PORT=15432 |
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 was deleted.
Oops, something went wrong.
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,17 +1,17 @@ | ||
""" Tests to ensure that the json_schema end-points work correctly. | ||
""" | ||
from http import HTTPStatus | ||
# """ Tests to ensure that the json_schema end-points work correctly. | ||
# """ | ||
# from http import HTTPStatus | ||
|
||
import pytest | ||
# import pytest | ||
|
||
|
||
@pytest.mark.parametrize( | ||
"test_name, schema_name, expected_status", | ||
[ | ||
("Existing schema", "components", HTTPStatus.OK), | ||
("Non existing schema", "nonExistingSchema", HTTPStatus.NOT_FOUND) | ||
], | ||
) | ||
def test_get_schema(client, session, test_name, schema_name, expected_status): | ||
rv = client.get(f'/json-schemas/{schema_name}') | ||
assert rv.status_code == expected_status | ||
# @pytest.mark.parametrize( | ||
# "test_name, schema_name, expected_status", | ||
# [ | ||
# ("Existing schema", "components", HTTPStatus.OK), | ||
# ("Non existing schema", "nonExistingSchema", HTTPStatus.NOT_FOUND) | ||
# ], | ||
# ) | ||
# def test_get_schema(client, session, test_name, schema_name, expected_status): | ||
# rv = client.get(f'/json-schemas/{schema_name}') | ||
# assert rv.status_code == expected_status |
Oops, something went wrong.