| 1 |
from globus_sdk.testing.models import RegisteredResponse, ResponseSet |
| 2 |
|
| 3 |
metadata = { |
| 4 |
"id": "daa09846-eb92-11e9-b89c-9cb6d0d9fd63", |
| 5 |
"display_name": "example gateway 1", |
| 6 |
} |
| 7 |
|
| 8 |
RESPONSES = ResponseSet( |
| 9 |
metadata=metadata, |
| 10 |
default=RegisteredResponse( |
| 11 |
service="gcs", |
| 12 |
path=f"/storage_gateways/{metadata['id']}", |
| 13 |
json={ |
| 14 |
"DATA_TYPE": "result#1.0.0", |
| 15 |
"http_response_code": 200, |
| 16 |
"detail": "success", |
| 17 |
"message": "Operation successful", |
| 18 |
"code": "success", |
| 19 |
"data": [ |
| 20 |
{ |
| 21 |
"DATA_TYPE": "storage_gateway#1.0.0", |
| 22 |
"id": metadata["id"], |
| 23 |
"display_name": metadata["display_name"], |
| 24 |
"connector_id": "145812c8-decc-41f1-83cf-bb2a85a2a70b", |
| 25 |
"high_assurance": False, |
| 26 |
"authentication_assurance_timeout": 15840, |
| 27 |
"authentication_timeout_mins": 15840, |
| 28 |
"allowed_domains": ["example.edu"], |
| 29 |
"mapping": "username_without_domain", |
| 30 |
"require_high_assurance": False, |
| 31 |
"restrict_paths": { |
| 32 |
"DATA_TYPE": "path_restrictions#1.0.0", |
| 33 |
"read": ["/"], |
| 34 |
}, |
| 35 |
"policies": { |
| 36 |
"DATA_TYPE": "posix_storage_gateway#1.0.0", |
| 37 |
"groups_allow": ["globus"], |
| 38 |
"groups_deny": ["nonglobus"], |
| 39 |
}, |
| 40 |
"users_allow": ["user1"], |
| 41 |
"users_deny": ["user2"], |
| 42 |
} |
| 43 |
], |
| 44 |
}, |
| 45 |
), |
| 46 |
) |