Skip to content

Commit

Permalink
chore(c999): regression test, ensure testing common exchange area for…
Browse files Browse the repository at this point in the history
… c999
  • Loading branch information
Avantol13 committed Jan 22, 2025
1 parent 87d4649 commit 964b1a9
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 8 deletions.
3 changes: 2 additions & 1 deletion tests/test-fence-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -345,13 +345,14 @@ dbGaP:
# have access to the parent study's "common exchange area data" that is not study
# specific. The following config is whether or not to parse/handle "c999" codes
# for exchange area data
enable_common_exchange_area_access: false
enable_common_exchange_area_access: true
# The below configuration is a mapping from studies to their "common exchange area data"
# Fence project name a user gets access to when parsing c999 exchange area codes (and
# subsequently gives access to an arborist resource representing this common area
# as well)
study_common_exchange_areas:
'phs000178': 'test_common_exchange_area'
'phs000298': 'test_common_exchange_area_2'
# A mapping from the dbgap study / Fence project to which authorization namespaces the
# actual data lives in. For example, `studyX` data may exist in multiple organizations, so
# we need to know to map authorization to all orgs resources
Expand Down
14 changes: 7 additions & 7 deletions tests/test_drs.py
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,7 @@ def test_passport_use_disabled(
"phs_id": "phs000298",
"version": "v4",
"participant_set": "p3",
"consent_group": "c1",
"consent_group": "c999",
"role": "designated user",
"expiration": int(time.time()) + 1001,
},
Expand Down Expand Up @@ -520,7 +520,7 @@ def test_get_presigned_url_for_non_public_data_with_passport(
"phs_id": "phs000298",
"version": "v4",
"participant_set": "p3",
"consent_group": "c1",
"consent_group": "c999",
"role": "designated user",
"expiration": int(time.time()) + 1001,
},
Expand Down Expand Up @@ -678,7 +678,7 @@ def test_get_presigned_url_with_passport_with_incorrect_authz(
"phs_id": "phs000298",
"version": "v4",
"participant_set": "p3",
"consent_group": "c1",
"consent_group": "c999",
"role": "designated user",
"expiration": int(time.time()) + 1001,
},
Expand Down Expand Up @@ -974,7 +974,7 @@ def test_passport_cache_valid_passport(
"phs_id": "phs000298",
"version": "v4",
"participant_set": "p3",
"consent_group": "c1",
"consent_group": "c999",
"role": "designated user",
"expiration": current_time + 1000,
},
Expand Down Expand Up @@ -1187,7 +1187,7 @@ def test_passport_cache_invalid_passport(
"phs_id": "phs000298",
"version": "v4",
"participant_set": "p3",
"consent_group": "c1",
"consent_group": "c999",
"role": "designated user",
"expiration": current_time + 1000,
},
Expand Down Expand Up @@ -1404,7 +1404,7 @@ def test_passport_cache_expired_in_memory_valid_in_db(
"phs_id": "phs000298",
"version": "v4",
"participant_set": "p3",
"consent_group": "c1",
"consent_group": "c999",
"role": "designated user",
"expiration": current_time + 1000,
},
Expand Down Expand Up @@ -1635,7 +1635,7 @@ def test_passport_cache_expired(
"phs_id": "phs000298",
"version": "v4",
"participant_set": "p3",
"consent_group": "c1",
"consent_group": "c999",
"role": "designated user",
"expiration": current_time + 2,
},
Expand Down

0 comments on commit 964b1a9

Please sign in to comment.