Skip to content
Snippets Groups Projects

TST: filestem response url

Merged Timm Fitschen requested to merge f-filesystem-response-url into dev
2 files
+ 457
550
Compare changes
  • Side-by-side
  • Inline

Files

+ 21
0
@@ -60,6 +60,27 @@ def test_file_system_returns_ids(clear_database):
assert search in str(body)
def test_file_system_returns_correct_url_with_proxy(clear_database):
c = db.get_connection()
resp = c.retrieve(
entity_uri_segments=["FileSystem"],
headers={"X-Forwarded-Proto": "myscheme"},
reconnect=True)
body = resp.read()
print(body)
search = 'url="myscheme://'
assert search in str(body)
resp = c.retrieve(
entity_uri_segments=["FileSystem"],
headers={"Forwarded": "by=byid;for=forid;host=hostaddress;proto=myother"},
reconnect=True)
body = resp.read()
print(body)
search = 'url="myother://'
assert search in str(body)
def test_sat_query_with_leading_slash(clear_database):
upload_file = open("test.dat", "w")
upload_file.write("hello world\n")
Loading