-
Notifications
You must be signed in to change notification settings - Fork 4
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
1 parent
aa39a81
commit 7ffc4b8
Showing
7 changed files
with
54 additions
and
2 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
from icat.query import Query | ||
import pytest | ||
|
||
|
||
@pytest.fixture() | ||
def icat_query(icat_client): | ||
return Query(icat_client, "Investigation") | ||
|
||
|
||
@pytest.fixture() | ||
def bad_credentials_header(): | ||
return {"Authorization": "Bearer Invalid"} | ||
|
||
|
||
@pytest.fixture() | ||
def invalid_credentials_header(): | ||
return {"Authorization": "Test"} | ||
|
||
|
||
@pytest.fixture() | ||
def test_config_data(): | ||
return { | ||
"datagateway_api": { | ||
"extension": "/datagateway-api", | ||
"backend": "db", | ||
"client_cache_size": 5, | ||
"client_pool_init_size": 2, | ||
"client_pool_max_size": 5, | ||
"db_url": "mysql+pymysql://icatdbuser:icatdbuserpw@localhost:3306/icatdb", | ||
"icat_url": "https://localhost:8181", | ||
"icat_check_cert": False, | ||
}, | ||
"search_api": { | ||
"extension": "/search-api", | ||
"icat_url": "https://localhost.testdomain:8181", | ||
"icat_check_cert": True, | ||
"mechanism": "anon", | ||
"username": "", | ||
"password": "", | ||
}, | ||
"flask_reloader": False, | ||
"log_level": "WARN", | ||
"log_location": "/home/runner/work/datagateway-api/datagateway-api/logs.log", | ||
"debug_mode": False, | ||
"generate_swagger": False, | ||
"host": "127.0.0.1", | ||
"port": "5000", | ||
"test_user_credentials": {"username": "root", "password": "pw"}, | ||
"test_mechanism": "simple", | ||
} |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
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