-
Notifications
You must be signed in to change notification settings - Fork 282
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Clean up emulator check in Cosmos Test (#2547)
* clean up emulator check * don't perform install path check * move IO test from ctor tests and move cleanup * - re-recorded tests - adjusted setup * cleanup * switch to before * re-recorded cosmos tests * also display 'cant connect' message when in lockdown * increase timeout for Cosmos Base Storage Tests Co-authored-by: stevengum <[email protected]>
- Loading branch information
1 parent
916728e
commit 0480b9d
Showing
12 changed files
with
2,175 additions
and
1,830 deletions.
There are no files selected for viewing
314 changes: 157 additions & 157 deletions
314
...zure/tests/TestData/CosmosDbPartitionedStorage - Base Storage Tests/create_an_object.json
Large diffs are not rendered by default.
Oops, something went wrong.
250 changes: 125 additions & 125 deletions
250
...zure/tests/TestData/CosmosDbPartitionedStorage - Base Storage Tests/delete_an_object.json
Large diffs are not rendered by default.
Oops, something went wrong.
110 changes: 55 additions & 55 deletions
110
...rtitionedStorage - Base Storage Tests/does_not_throw_when_deleting_an_unknown_object.json
Large diffs are not rendered by default.
Oops, something went wrong.
200 changes: 100 additions & 100 deletions
200
...ure/tests/TestData/CosmosDbPartitionedStorage - Base Storage Tests/handle_crazy_keys.json
Large diffs are not rendered by default.
Oops, something went wrong.
331 changes: 331 additions & 0 deletions
331
...DbPartitionedStorage - Base Storage Tests/passes_cosmosClientOptions_to_CosmosClient.json
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,331 @@ | ||
[ | ||
{ | ||
"scope": "https://localhost:8081", | ||
"method": "GET", | ||
"path": "/", | ||
"body": "", | ||
"status": 200, | ||
"response": { | ||
"_self": "", | ||
"id": "localhost", | ||
"_rid": "localhost", | ||
"media": "//media/", | ||
"addresses": "//addresses/", | ||
"_dbs": "//dbs/", | ||
"writableLocations": [ | ||
{ | ||
"name": "South Central US", | ||
"databaseAccountEndpoint": "https://127.0.0.1:8081/" | ||
} | ||
], | ||
"readableLocations": [ | ||
{ | ||
"name": "South Central US", | ||
"databaseAccountEndpoint": "https://127.0.0.1:8081/" | ||
} | ||
], | ||
"enableMultipleWriteLocations": false, | ||
"userReplicationPolicy": { | ||
"asyncReplication": false, | ||
"minReplicaSetSize": 1, | ||
"maxReplicasetSize": 4 | ||
}, | ||
"userConsistencyPolicy": { | ||
"defaultConsistencyLevel": "Session" | ||
}, | ||
"systemReplicationPolicy": { | ||
"minReplicaSetSize": 1, | ||
"maxReplicasetSize": 4 | ||
}, | ||
"readPolicy": { | ||
"primaryReadCoefficient": 1, | ||
"secondaryReadCoefficient": 1 | ||
}, | ||
"queryEngineConfiguration": "{\"maxSqlQueryInputLength\":262144,\"maxJoinsPerSqlQuery\":5,\"maxLogicalAndPerSqlQuery\":500,\"maxLogicalOrPerSqlQuery\":500,\"maxUdfRefPerSqlQuery\":10,\"maxInExpressionItemsCount\":16000,\"queryMaxInMemorySortDocumentCount\":500,\"maxQueryRequestTimeoutFraction\":0.9,\"sqlAllowNonFiniteNumbers\":false,\"sqlAllowAggregateFunctions\":true,\"sqlAllowSubQuery\":true,\"sqlAllowScalarSubQuery\":true,\"allowNewKeywords\":true,\"sqlAllowLike\":false,\"sqlAllowGroupByClause\":true,\"maxSpatialQueryCells\":12,\"spatialMaxGeometryPointCount\":256,\"sqlDisableQueryILOptimization\":false,\"sqlAllowTop\":true,\"enableSpatialIndexing\":true}" | ||
}, | ||
"rawHeaders": [ | ||
"Cache-Control", | ||
"no-store, no-cache", | ||
"Pragma", | ||
"no-cache", | ||
"Transfer-Encoding", | ||
"chunked", | ||
"Content-Type", | ||
"application/json", | ||
"Content-Location", | ||
"https://localhost:8081/", | ||
"Server", | ||
"Microsoft-HTTPAPI/2.0", | ||
"Access-Control-Allow-Origin", | ||
"", | ||
"Access-Control-Allow-Credentials", | ||
"true", | ||
"x-ms-max-media-storage-usage-mb", | ||
"10240", | ||
"x-ms-media-storage-usage-mb", | ||
"0", | ||
"x-ms-databaseaccount-consumed-mb", | ||
"0", | ||
"x-ms-databaseaccount-reserved-mb", | ||
"0", | ||
"x-ms-databaseaccount-provisioned-mb", | ||
"0", | ||
"x-ms-gatewayversion", | ||
"version=2.9.2", | ||
"Date", | ||
"Tue, 21 Jul 2020 00:00:01 GMT", | ||
"Connection", | ||
"close" | ||
], | ||
"responseIsBinary": false | ||
}, | ||
{ | ||
"scope": "https://localhost:8081", | ||
"method": "GET", | ||
"path": "/dbs/CosmosPartitionedStorageTestDb/colls/CosmosPartitionedStorageTestContainer-8", | ||
"body": "", | ||
"status": 404, | ||
"response": { | ||
"code": "NotFound", | ||
"message": "Message: {\"Errors\":[\"Resource Not Found\"]}\r\nActivityId: 10ab05b9-74e7-4f7b-ae5c-44a11259d412, Request URI: /apps/DocDbApp/services/DocDbMaster0/partitions/780e44f4-38c8-11e6-8106-8cdcd42c33be/replicas/1p/, RequestStats: \r\nRequestStartTime: 2020-07-21T00:00:01.9498785Z, RequestEndTime: 2020-07-21T00:00:01.9558824Z, Number of regions attempted:1\r\nResponseTime: 2020-07-21T00:00:01.9558824Z, StoreResult: StorePhysicalAddress: rntbd://127.0.0.1:10251/apps/DocDbApp/services/DocDbMaster0/partitions/780e44f4-38c8-11e6-8106-8cdcd42c33be/replicas/1p/, LSN: 5629, GlobalCommittedLsn: -1, PartitionKeyRangeId: , IsValid: True, StatusCode: 404, SubStatusCode: 0, RequestCharge: 1, ItemLSN: -1, SessionToken: -1#5629, UsingLocalLSN: False, TransportException: null, ResourceType: Collection, OperationType: Read\r\nResponseTime: 2020-07-21T00:00:01.9558824Z, StoreResult: StorePhysicalAddress: rntbd://127.0.0.1:10251/apps/DocDbApp/services/DocDbMaster0/partitions/780e44f4-38c8-11e6-8106-8cdcd42c33be/replicas/1p/, LSN: 5629, GlobalCommittedLsn: -1, PartitionKeyRangeId: , IsValid: True, StatusCode: 404, SubStatusCode: 0, RequestCharge: 1, ItemLSN: -1, SessionToken: -1#5629, UsingLocalLSN: False, TransportException: null, ResourceType: Collection, OperationType: Read\r\n, SDK: Microsoft.Azure.Documents.Common/2.9.2" | ||
}, | ||
"rawHeaders": [ | ||
"Transfer-Encoding", | ||
"chunked", | ||
"Content-Type", | ||
"application/json", | ||
"Content-Location", | ||
"https://localhost:8081/dbs/CosmosPartitionedStorageTestDb/colls/CosmosPartitionedStorageTestContainer-8", | ||
"Server", | ||
"Microsoft-HTTPAPI/2.0", | ||
"Access-Control-Allow-Origin", | ||
"", | ||
"Access-Control-Allow-Credentials", | ||
"true", | ||
"x-ms-last-state-change-utc", | ||
"Mon, 20 Jul 2020 23:59:34.506 GMT", | ||
"lsn", | ||
"5629", | ||
"x-ms-schemaversion", | ||
"1.9", | ||
"x-ms-quorum-acked-lsn", | ||
"5629", | ||
"x-ms-current-write-quorum", | ||
"1", | ||
"x-ms-current-replica-set-size", | ||
"1", | ||
"x-ms-xp-role", | ||
"0", | ||
"x-ms-global-Committed-lsn", | ||
"-1", | ||
"x-ms-number-of-read-regions", | ||
"0", | ||
"x-ms-transport-request-id", | ||
"8", | ||
"x-ms-cosmos-llsn", | ||
"5629", | ||
"x-ms-cosmos-quorum-acked-llsn", | ||
"5629", | ||
"x-ms-session-token", | ||
"0:-1#5629", | ||
"x-ms-request-charge", | ||
"2", | ||
"x-ms-serviceversion", | ||
"version=2.9.0.0", | ||
"x-ms-activity-id", | ||
"10ab05b9-74e7-4f7b-ae5c-44a11259d412", | ||
"x-ms-gatewayversion", | ||
"version=2.9.2", | ||
"Date", | ||
"Tue, 21 Jul 2020 00:00:01 GMT", | ||
"Connection", | ||
"close" | ||
], | ||
"responseIsBinary": false | ||
}, | ||
{ | ||
"scope": "https://localhost:8081", | ||
"method": "GET", | ||
"path": "/dbs/CosmosPartitionedStorageTestDb/colls/CosmosPartitionedStorageTestContainer-8", | ||
"body": "", | ||
"status": 404, | ||
"response": { | ||
"code": "NotFound", | ||
"message": "Message: {\"Errors\":[\"Resource Not Found\"]}\r\nActivityId: 66cbb92f-e2f5-4c68-ac11-9793a703dd6e, Request URI: /apps/DocDbApp/services/DocDbMaster0/partitions/780e44f4-38c8-11e6-8106-8cdcd42c33be/replicas/1p/, RequestStats: \r\nRequestStartTime: 2020-07-21T00:00:01.9728776Z, RequestEndTime: 2020-07-21T00:00:01.9748775Z, Number of regions attempted:1\r\nResponseTime: 2020-07-21T00:00:01.9748775Z, StoreResult: StorePhysicalAddress: rntbd://127.0.0.1:10251/apps/DocDbApp/services/DocDbMaster0/partitions/780e44f4-38c8-11e6-8106-8cdcd42c33be/replicas/1p/, LSN: 5629, GlobalCommittedLsn: -1, PartitionKeyRangeId: , IsValid: True, StatusCode: 404, SubStatusCode: 0, RequestCharge: 1, ItemLSN: -1, SessionToken: -1#5629, UsingLocalLSN: False, TransportException: null, ResourceType: Collection, OperationType: Read\r\nResponseTime: 2020-07-21T00:00:01.9748775Z, StoreResult: StorePhysicalAddress: rntbd://127.0.0.1:10251/apps/DocDbApp/services/DocDbMaster0/partitions/780e44f4-38c8-11e6-8106-8cdcd42c33be/replicas/1p/, LSN: 5629, GlobalCommittedLsn: -1, PartitionKeyRangeId: , IsValid: True, StatusCode: 404, SubStatusCode: 0, RequestCharge: 1, ItemLSN: -1, SessionToken: -1#5629, UsingLocalLSN: False, TransportException: null, ResourceType: Collection, OperationType: Read\r\n, SDK: Microsoft.Azure.Documents.Common/2.9.2" | ||
}, | ||
"rawHeaders": [ | ||
"Transfer-Encoding", | ||
"chunked", | ||
"Content-Type", | ||
"application/json", | ||
"Content-Location", | ||
"https://localhost:8081/dbs/CosmosPartitionedStorageTestDb/colls/CosmosPartitionedStorageTestContainer-8", | ||
"Server", | ||
"Microsoft-HTTPAPI/2.0", | ||
"Access-Control-Allow-Origin", | ||
"", | ||
"Access-Control-Allow-Credentials", | ||
"true", | ||
"x-ms-last-state-change-utc", | ||
"Mon, 20 Jul 2020 23:59:34.506 GMT", | ||
"lsn", | ||
"5629", | ||
"x-ms-schemaversion", | ||
"1.9", | ||
"x-ms-quorum-acked-lsn", | ||
"5629", | ||
"x-ms-current-write-quorum", | ||
"1", | ||
"x-ms-current-replica-set-size", | ||
"1", | ||
"x-ms-xp-role", | ||
"0", | ||
"x-ms-global-Committed-lsn", | ||
"-1", | ||
"x-ms-number-of-read-regions", | ||
"0", | ||
"x-ms-transport-request-id", | ||
"10", | ||
"x-ms-cosmos-llsn", | ||
"5629", | ||
"x-ms-cosmos-quorum-acked-llsn", | ||
"5629", | ||
"x-ms-session-token", | ||
"0:-1#5629", | ||
"x-ms-request-charge", | ||
"2", | ||
"x-ms-serviceversion", | ||
"version=2.9.0.0", | ||
"x-ms-activity-id", | ||
"66cbb92f-e2f5-4c68-ac11-9793a703dd6e", | ||
"x-ms-gatewayversion", | ||
"version=2.9.2", | ||
"Date", | ||
"Tue, 21 Jul 2020 00:00:01 GMT", | ||
"Connection", | ||
"close" | ||
], | ||
"responseIsBinary": false | ||
}, | ||
{ | ||
"scope": "https://localhost:8081", | ||
"method": "POST", | ||
"path": "/dbs/CosmosPartitionedStorageTestDb/colls", | ||
"body": { | ||
"id": "CosmosPartitionedStorageTestContainer-8", | ||
"partitionKey": { | ||
"paths": [ | ||
"/id" | ||
] | ||
} | ||
}, | ||
"status": 201, | ||
"response": { | ||
"id": "CosmosPartitionedStorageTestContainer-8", | ||
"indexingPolicy": { | ||
"indexingMode": "consistent", | ||
"automatic": true, | ||
"includedPaths": [ | ||
{ | ||
"path": "/*" | ||
} | ||
], | ||
"excludedPaths": [ | ||
{ | ||
"path": "/\"_etag\"/?" | ||
} | ||
] | ||
}, | ||
"partitionKey": { | ||
"paths": [ | ||
"/id" | ||
], | ||
"kind": "Hash" | ||
}, | ||
"conflictResolutionPolicy": { | ||
"mode": "LastWriterWins", | ||
"conflictResolutionPath": "/_ts", | ||
"conflictResolutionProcedure": "" | ||
}, | ||
"geospatialConfig": { | ||
"type": "Geography" | ||
}, | ||
"_rid": "DIQKAJDwXJQ=", | ||
"_ts": 1595289602, | ||
"_self": "dbs/DIQKAA==/colls/DIQKAJDwXJQ=/", | ||
"_etag": "\"00000000-0000-0000-5ef1-e1ef51d001d6\"", | ||
"_docs": "docs/", | ||
"_sprocs": "sprocs/", | ||
"_triggers": "triggers/", | ||
"_udfs": "udfs/", | ||
"_conflicts": "conflicts/" | ||
}, | ||
"rawHeaders": [ | ||
"Cache-Control", | ||
"no-store, no-cache", | ||
"Pragma", | ||
"no-cache", | ||
"Transfer-Encoding", | ||
"chunked", | ||
"Content-Type", | ||
"application/json", | ||
"Server", | ||
"Microsoft-HTTPAPI/2.0", | ||
"Access-Control-Allow-Origin", | ||
"", | ||
"Access-Control-Allow-Credentials", | ||
"true", | ||
"x-ms-last-state-change-utc", | ||
"Mon, 20 Jul 2020 23:59:42.579 GMT", | ||
"etag", | ||
"\"00000000-0000-0000-5ef1-e1ef51d001d6\"", | ||
"collection-partition-index", | ||
"0", | ||
"collection-service-index", | ||
"0", | ||
"lsn", | ||
"3448", | ||
"x-ms-schemaversion", | ||
"1.9", | ||
"x-ms-alt-content-path", | ||
"dbs/CosmosPartitionedStorageTestDb", | ||
"x-ms-quorum-acked-lsn", | ||
"3448", | ||
"x-ms-current-write-quorum", | ||
"1", | ||
"x-ms-current-replica-set-size", | ||
"1", | ||
"x-ms-xp-role", | ||
"0", | ||
"x-ms-global-Committed-lsn", | ||
"-1", | ||
"x-ms-number-of-read-regions", | ||
"0", | ||
"x-ms-item-lsn", | ||
"3448", | ||
"x-ms-transport-request-id", | ||
"2", | ||
"x-ms-cosmos-llsn", | ||
"3448", | ||
"x-ms-cosmos-quorum-acked-llsn", | ||
"3448", | ||
"x-ms-cosmos-item-llsn", | ||
"3448", | ||
"x-ms-session-token", | ||
"0:-1#3448", | ||
"x-ms-request-charge", | ||
"1", | ||
"x-ms-serviceversion", | ||
"version=2.9.0.0", | ||
"x-ms-activity-id", | ||
"c1c7a10c-440c-49d3-9488-805d7d1affb2", | ||
"x-ms-gatewayversion", | ||
"version=2.9.2", | ||
"Date", | ||
"Tue, 21 Jul 2020 00:00:02 GMT", | ||
"Connection", | ||
"close" | ||
], | ||
"responseIsBinary": false | ||
} | ||
] |
Oops, something went wrong.