Skip to content
This repository has been archived by the owner on May 5, 2023. It is now read-only.

Commit

Permalink
Update test cases to use 2018-12-01 api version
Browse files Browse the repository at this point in the history
  • Loading branch information
xingwu1 committed Dec 11, 2018
1 parent c33cf37 commit 59b0457
Show file tree
Hide file tree
Showing 101 changed files with 1,614 additions and 1,910 deletions.
2 changes: 1 addition & 1 deletion lib/services/batch/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"contributors": [
"Wu, Xing <[email protected]>"
],
"version": "4.1.0",
"version": "5.0.0",
"description": "Microsoft Azure Batch Service Client Library for node",
"tags": [
"azure",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,102 +1,102 @@
// This file has been autogenerated.

exports.setEnvironment = function() {
process.env['AZURE_BATCH_ACCOUNT'] = 'lchency4';
process.env['AZURE_BATCH_ENDPOINT'] = 'https://lchency4.westcentralus.batch.azure.com';
process.env['AZURE_SUBSCRIPTION_ID'] = '3ee7eaf5-6a2f-49fd-953f-d760b5ac2e05';
process.env['AZURE_BATCH_ACCOUNT'] = 'test3';
process.env['AZURE_BATCH_ENDPOINT'] = 'https://test3.westcentralus.batch.azure.com';
process.env['AZURE_SUBSCRIPTION_ID'] = 'f30ef677-64a9-4768-934f-5fbbc0e1ad27';
};

exports.scopes = [[function (nock) {
var result =
nock('http://lchency4.westcentralus.batch.azure.com:443')
nock('http://test3.westcentralus.batch.azure.com:443')
.filteringRequestBody(function (path) { return '*';})
.post('/pools?api-version=2018-08-01.7.0', '*')
.post('/pools?api-version=2018-12-01.8.0', '*')
.reply(201, "", { 'transfer-encoding': 'chunked',
'last-modified': 'Tue, 21 Aug 2018 20:16:25 GMT',
etag: '0x8D607A2F88AD288',
location: 'https://lchency4.westcentralus.batch.azure.com/pools/nodesdkdatadiskpool',
'last-modified': 'Tue, 11 Dec 2018 18:35:46 GMT',
etag: '0x8D65F9777899C68',
location: 'https://test3.westcentralus.batch.azure.com/pools/nodesdkdatadiskpool',
server: 'Microsoft-HTTPAPI/2.0',
'request-id': '6f31d928-5f1c-42c4-8c80-5d4b3e375120',
'request-id': 'c2eca7f6-6004-4139-b490-d61cad4ab1c5',
'strict-transport-security': 'max-age=31536000; includeSubDomains',
'x-content-type-options': 'nosniff',
dataserviceversion: '3.0',
dataserviceid: 'https://lchency4.westcentralus.batch.azure.com/pools/nodesdkdatadiskpool',
date: 'Tue, 21 Aug 2018 20:16:25 GMT',
dataserviceid: 'https://test3.westcentralus.batch.azure.com/pools/nodesdkdatadiskpool',
date: 'Tue, 11 Dec 2018 18:35:46 GMT',
connection: 'close' });
return result; },
function (nock) {
var result =
nock('https://lchency4.westcentralus.batch.azure.com:443')
nock('https://test3.westcentralus.batch.azure.com:443')
.filteringRequestBody(function (path) { return '*';})
.post('/pools?api-version=2018-08-01.7.0', '*')
.post('/pools?api-version=2018-12-01.8.0', '*')
.reply(201, "", { 'transfer-encoding': 'chunked',
'last-modified': 'Tue, 21 Aug 2018 20:16:25 GMT',
etag: '0x8D607A2F88AD288',
location: 'https://lchency4.westcentralus.batch.azure.com/pools/nodesdkdatadiskpool',
'last-modified': 'Tue, 11 Dec 2018 18:35:46 GMT',
etag: '0x8D65F9777899C68',
location: 'https://test3.westcentralus.batch.azure.com/pools/nodesdkdatadiskpool',
server: 'Microsoft-HTTPAPI/2.0',
'request-id': '6f31d928-5f1c-42c4-8c80-5d4b3e375120',
'request-id': 'c2eca7f6-6004-4139-b490-d61cad4ab1c5',
'strict-transport-security': 'max-age=31536000; includeSubDomains',
'x-content-type-options': 'nosniff',
dataserviceversion: '3.0',
dataserviceid: 'https://lchency4.westcentralus.batch.azure.com/pools/nodesdkdatadiskpool',
date: 'Tue, 21 Aug 2018 20:16:25 GMT',
dataserviceid: 'https://test3.westcentralus.batch.azure.com/pools/nodesdkdatadiskpool',
date: 'Tue, 11 Dec 2018 18:35:46 GMT',
connection: 'close' });
return result; },
function (nock) {
var result =
nock('http://lchency4.westcentralus.batch.azure.com:443')
.get('/pools/nodesdkdatadiskpool?api-version=2018-08-01.7.0')
.reply(200, "{\r\n \"odata.metadata\":\"https://lchency4.westcentralus.batch.azure.com/$metadata#pools/@Element\",\"id\":\"nodesdkdatadiskpool\",\"url\":\"https://lchency4.westcentralus.batch.azure.com/pools/nodesdkdatadiskpool\",\"eTag\":\"0x8D607A2F88AD288\",\"lastModified\":\"2018-08-21T20:16:25.5447688Z\",\"creationTime\":\"2018-08-21T20:16:25.5447688Z\",\"state\":\"active\",\"stateTransitionTime\":\"2018-08-21T20:16:25.5447688Z\",\"allocationState\":\"resizing\",\"allocationStateTransitionTime\":\"2018-08-21T20:16:25.5447688Z\",\"vmSize\":\"standard_a1\",\"resizeTimeout\":\"PT15M\",\"currentDedicatedNodes\":0,\"targetDedicatedNodes\":0,\"currentLowPriorityNodes\":0,\"targetLowPriorityNodes\":0,\"enableAutoScale\":false,\"enableInterNodeCommunication\":false,\"maxTasksPerNode\":1,\"taskSchedulingPolicy\":{\r\n \"nodeFillType\":\"Spread\"\r\n },\"virtualMachineConfiguration\":{\r\n \"imageReference\":{\r\n \"publisher\":\"Canonical\",\"offer\":\"UbuntuServer\",\"sku\":\"16.04-LTS\",\"version\":\"latest\"\r\n },\"nodeAgentSKUId\":\"batch.node.ubuntu 16.04\",\"dataDisks\":[\r\n {\r\n \"lun\":1,\"caching\":\"none\",\"diskSizeGB\":50,\"storageAccountType\":\"standard_lrs\"\r\n }\r\n ]\r\n }\r\n}", { 'transfer-encoding': 'chunked',
nock('http://test3.westcentralus.batch.azure.com:443')
.get('/pools/nodesdkdatadiskpool?api-version=2018-12-01.8.0')
.reply(200, "{\r\n \"odata.metadata\":\"https://test3.westcentralus.batch.azure.com/$metadata#pools/@Element\",\"id\":\"nodesdkdatadiskpool\",\"url\":\"https://test3.westcentralus.batch.azure.com/pools/nodesdkdatadiskpool\",\"eTag\":\"0x8D65F9777899C68\",\"lastModified\":\"2018-12-11T18:35:46.9711464Z\",\"creationTime\":\"2018-12-11T18:35:46.9711464Z\",\"state\":\"active\",\"stateTransitionTime\":\"2018-12-11T18:35:46.9711464Z\",\"allocationState\":\"resizing\",\"allocationStateTransitionTime\":\"2018-12-11T18:35:46.9711464Z\",\"vmSize\":\"standard_a1\",\"resizeTimeout\":\"PT15M\",\"currentDedicatedNodes\":0,\"targetDedicatedNodes\":0,\"currentLowPriorityNodes\":0,\"targetLowPriorityNodes\":0,\"enableAutoScale\":false,\"enableInterNodeCommunication\":false,\"maxTasksPerNode\":1,\"taskSchedulingPolicy\":{\r\n \"nodeFillType\":\"Spread\"\r\n },\"virtualMachineConfiguration\":{\r\n \"imageReference\":{\r\n \"publisher\":\"Canonical\",\"offer\":\"UbuntuServer\",\"sku\":\"16.04-LTS\",\"version\":\"latest\"\r\n },\"nodeAgentSKUId\":\"batch.node.ubuntu 16.04\",\"dataDisks\":[\r\n {\r\n \"lun\":1,\"caching\":\"none\",\"diskSizeGB\":50,\"storageAccountType\":\"standard_lrs\"\r\n }\r\n ]\r\n }\r\n}", { 'transfer-encoding': 'chunked',
'content-type': 'application/json;odata=minimalmetadata',
'last-modified': 'Tue, 21 Aug 2018 20:16:25 GMT',
etag: '0x8D607A2F88AD288',
'last-modified': 'Tue, 11 Dec 2018 18:35:46 GMT',
etag: '0x8D65F9777899C68',
server: 'Microsoft-HTTPAPI/2.0',
'request-id': '0d063096-3873-4348-a001-2b3100b1ce89',
'request-id': '1c141802-5276-440e-9c1c-b0946f3425ef',
'strict-transport-security': 'max-age=31536000; includeSubDomains',
'x-content-type-options': 'nosniff',
dataserviceversion: '3.0',
date: 'Tue, 21 Aug 2018 20:16:25 GMT',
date: 'Tue, 11 Dec 2018 18:35:47 GMT',
connection: 'close' });
return result; },
function (nock) {
var result =
nock('https://lchency4.westcentralus.batch.azure.com:443')
.get('/pools/nodesdkdatadiskpool?api-version=2018-08-01.7.0')
.reply(200, "{\r\n \"odata.metadata\":\"https://lchency4.westcentralus.batch.azure.com/$metadata#pools/@Element\",\"id\":\"nodesdkdatadiskpool\",\"url\":\"https://lchency4.westcentralus.batch.azure.com/pools/nodesdkdatadiskpool\",\"eTag\":\"0x8D607A2F88AD288\",\"lastModified\":\"2018-08-21T20:16:25.5447688Z\",\"creationTime\":\"2018-08-21T20:16:25.5447688Z\",\"state\":\"active\",\"stateTransitionTime\":\"2018-08-21T20:16:25.5447688Z\",\"allocationState\":\"resizing\",\"allocationStateTransitionTime\":\"2018-08-21T20:16:25.5447688Z\",\"vmSize\":\"standard_a1\",\"resizeTimeout\":\"PT15M\",\"currentDedicatedNodes\":0,\"targetDedicatedNodes\":0,\"currentLowPriorityNodes\":0,\"targetLowPriorityNodes\":0,\"enableAutoScale\":false,\"enableInterNodeCommunication\":false,\"maxTasksPerNode\":1,\"taskSchedulingPolicy\":{\r\n \"nodeFillType\":\"Spread\"\r\n },\"virtualMachineConfiguration\":{\r\n \"imageReference\":{\r\n \"publisher\":\"Canonical\",\"offer\":\"UbuntuServer\",\"sku\":\"16.04-LTS\",\"version\":\"latest\"\r\n },\"nodeAgentSKUId\":\"batch.node.ubuntu 16.04\",\"dataDisks\":[\r\n {\r\n \"lun\":1,\"caching\":\"none\",\"diskSizeGB\":50,\"storageAccountType\":\"standard_lrs\"\r\n }\r\n ]\r\n }\r\n}", { 'transfer-encoding': 'chunked',
nock('https://test3.westcentralus.batch.azure.com:443')
.get('/pools/nodesdkdatadiskpool?api-version=2018-12-01.8.0')
.reply(200, "{\r\n \"odata.metadata\":\"https://test3.westcentralus.batch.azure.com/$metadata#pools/@Element\",\"id\":\"nodesdkdatadiskpool\",\"url\":\"https://test3.westcentralus.batch.azure.com/pools/nodesdkdatadiskpool\",\"eTag\":\"0x8D65F9777899C68\",\"lastModified\":\"2018-12-11T18:35:46.9711464Z\",\"creationTime\":\"2018-12-11T18:35:46.9711464Z\",\"state\":\"active\",\"stateTransitionTime\":\"2018-12-11T18:35:46.9711464Z\",\"allocationState\":\"resizing\",\"allocationStateTransitionTime\":\"2018-12-11T18:35:46.9711464Z\",\"vmSize\":\"standard_a1\",\"resizeTimeout\":\"PT15M\",\"currentDedicatedNodes\":0,\"targetDedicatedNodes\":0,\"currentLowPriorityNodes\":0,\"targetLowPriorityNodes\":0,\"enableAutoScale\":false,\"enableInterNodeCommunication\":false,\"maxTasksPerNode\":1,\"taskSchedulingPolicy\":{\r\n \"nodeFillType\":\"Spread\"\r\n },\"virtualMachineConfiguration\":{\r\n \"imageReference\":{\r\n \"publisher\":\"Canonical\",\"offer\":\"UbuntuServer\",\"sku\":\"16.04-LTS\",\"version\":\"latest\"\r\n },\"nodeAgentSKUId\":\"batch.node.ubuntu 16.04\",\"dataDisks\":[\r\n {\r\n \"lun\":1,\"caching\":\"none\",\"diskSizeGB\":50,\"storageAccountType\":\"standard_lrs\"\r\n }\r\n ]\r\n }\r\n}", { 'transfer-encoding': 'chunked',
'content-type': 'application/json;odata=minimalmetadata',
'last-modified': 'Tue, 21 Aug 2018 20:16:25 GMT',
etag: '0x8D607A2F88AD288',
'last-modified': 'Tue, 11 Dec 2018 18:35:46 GMT',
etag: '0x8D65F9777899C68',
server: 'Microsoft-HTTPAPI/2.0',
'request-id': '0d063096-3873-4348-a001-2b3100b1ce89',
'request-id': '1c141802-5276-440e-9c1c-b0946f3425ef',
'strict-transport-security': 'max-age=31536000; includeSubDomains',
'x-content-type-options': 'nosniff',
dataserviceversion: '3.0',
date: 'Tue, 21 Aug 2018 20:16:25 GMT',
date: 'Tue, 11 Dec 2018 18:35:47 GMT',
connection: 'close' });
return result; },
function (nock) {
var result =
nock('http://lchency4.westcentralus.batch.azure.com:443')
.delete('/pools/nodesdkdatadiskpool?api-version=2018-08-01.7.0')
nock('http://test3.westcentralus.batch.azure.com:443')
.delete('/pools/nodesdkdatadiskpool?api-version=2018-12-01.8.0')
.reply(202, "", { 'transfer-encoding': 'chunked',
server: 'Microsoft-HTTPAPI/2.0',
'request-id': 'a7c4a31b-0870-4ce3-9af7-61970a395c1f',
'request-id': 'd401b919-e404-43a1-aebe-36954ab9d864',
'strict-transport-security': 'max-age=31536000; includeSubDomains',
'x-content-type-options': 'nosniff',
dataserviceversion: '3.0',
date: 'Tue, 21 Aug 2018 20:16:27 GMT',
date: 'Tue, 11 Dec 2018 18:35:46 GMT',
connection: 'close' });
return result; },
function (nock) {
var result =
nock('https://lchency4.westcentralus.batch.azure.com:443')
.delete('/pools/nodesdkdatadiskpool?api-version=2018-08-01.7.0')
nock('https://test3.westcentralus.batch.azure.com:443')
.delete('/pools/nodesdkdatadiskpool?api-version=2018-12-01.8.0')
.reply(202, "", { 'transfer-encoding': 'chunked',
server: 'Microsoft-HTTPAPI/2.0',
'request-id': 'a7c4a31b-0870-4ce3-9af7-61970a395c1f',
'request-id': 'd401b919-e404-43a1-aebe-36954ab9d864',
'strict-transport-security': 'max-age=31536000; includeSubDomains',
'x-content-type-options': 'nosniff',
dataserviceversion: '3.0',
date: 'Tue, 21 Aug 2018 20:16:27 GMT',
date: 'Tue, 11 Dec 2018 18:35:46 GMT',
connection: 'close' });
return result; }]];
Original file line number Diff line number Diff line change
@@ -1,38 +1,38 @@
// This file has been autogenerated.

exports.setEnvironment = function() {
process.env['AZURE_BATCH_ACCOUNT'] = 'lchency4';
process.env['AZURE_BATCH_ENDPOINT'] = 'https://lchency4.westcentralus.batch.azure.com';
process.env['AZURE_SUBSCRIPTION_ID'] = '3ee7eaf5-6a2f-49fd-953f-d760b5ac2e05';
process.env['AZURE_BATCH_ACCOUNT'] = 'test3';
process.env['AZURE_BATCH_ENDPOINT'] = 'https://test3.westcentralus.batch.azure.com';
process.env['AZURE_SUBSCRIPTION_ID'] = 'f30ef677-64a9-4768-934f-5fbbc0e1ad27';
};

exports.scopes = [[function (nock) {
var result =
nock('http://lchency4.westcentralus.batch.azure.com:443')
nock('http://test3.westcentralus.batch.azure.com:443')
.filteringRequestBody(function (path) { return '*';})
.post('/pools?api-version=2018-08-01.7.0', '*')
.reply(400, "{\r\n \"odata.metadata\":\"https://lchency4.westcentralus.batch.azure.com/$metadata#Microsoft.Azure.Batch.Protocol.Entities.Container.errors/@Element\",\"code\":\"InvalidPropertyValue\",\"message\":{\r\n \"lang\":\"en-US\",\"value\":\"The value provided for one of the properties in the request body is invalid.\\nRequestId:14df0f7d-179f-488c-942f-9ec1b6d12e5c\\nTime:2018-08-21T20:16:22.7758842Z\"\r\n },\"values\":[\r\n {\r\n \"key\":\"PropertyName\",\"value\":\"virtualMachineImageId\"\r\n },{\r\n \"key\":\"PropertyValue\",\"value\":\"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test/providers/Microsoft.Compute/images/FakeImage\"\r\n },{\r\n \"key\":\"Reason\",\"value\":\"The specified virtualMachineImageId is in a different subscription and cannot be used with the current Batch account in subscription 3ee7eaf5-6a2f-49fd-953f-d760b5ac2e05\"\r\n }\r\n ]\r\n}", { 'content-length': '852',
.post('/pools?api-version=2018-12-01.8.0', '*')
.reply(400, "{\r\n \"odata.metadata\":\"https://test3.westcentralus.batch.azure.com/$metadata#Microsoft.Azure.Batch.Protocol.Entities.Container.errors/@Element\",\"code\":\"InvalidPropertyValue\",\"message\":{\r\n \"lang\":\"en-US\",\"value\":\"The value provided for one of the properties in the request body is invalid.\\nRequestId:55bccad4-65eb-464a-b9db-73ce5fe322ca\\nTime:2018-12-11T18:35:45.1020145Z\"\r\n },\"values\":[\r\n {\r\n \"key\":\"PropertyName\",\"value\":\"virtualMachineImageId\"\r\n },{\r\n \"key\":\"PropertyValue\",\"value\":\"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test/providers/Microsoft.Compute/images/FakeImage\"\r\n },{\r\n \"key\":\"Reason\",\"value\":\"The specified virtualMachineImageId is in a different subscription and cannot be used with the current Batch account in subscription f30ef677-64a9-4768-934f-5fbbc0e1ad27\"\r\n }\r\n ]\r\n}", { 'content-length': '849',
'content-type': 'application/json;odata=minimalmetadata',
server: 'Microsoft-HTTPAPI/2.0',
'request-id': '14df0f7d-179f-488c-942f-9ec1b6d12e5c',
'request-id': '55bccad4-65eb-464a-b9db-73ce5fe322ca',
'strict-transport-security': 'max-age=31536000; includeSubDomains',
'x-content-type-options': 'nosniff',
dataserviceversion: '3.0',
date: 'Tue, 21 Aug 2018 20:16:22 GMT',
date: 'Tue, 11 Dec 2018 18:35:45 GMT',
connection: 'close' });
return result; },
function (nock) {
var result =
nock('https://lchency4.westcentralus.batch.azure.com:443')
nock('https://test3.westcentralus.batch.azure.com:443')
.filteringRequestBody(function (path) { return '*';})
.post('/pools?api-version=2018-08-01.7.0', '*')
.reply(400, "{\r\n \"odata.metadata\":\"https://lchency4.westcentralus.batch.azure.com/$metadata#Microsoft.Azure.Batch.Protocol.Entities.Container.errors/@Element\",\"code\":\"InvalidPropertyValue\",\"message\":{\r\n \"lang\":\"en-US\",\"value\":\"The value provided for one of the properties in the request body is invalid.\\nRequestId:14df0f7d-179f-488c-942f-9ec1b6d12e5c\\nTime:2018-08-21T20:16:22.7758842Z\"\r\n },\"values\":[\r\n {\r\n \"key\":\"PropertyName\",\"value\":\"virtualMachineImageId\"\r\n },{\r\n \"key\":\"PropertyValue\",\"value\":\"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test/providers/Microsoft.Compute/images/FakeImage\"\r\n },{\r\n \"key\":\"Reason\",\"value\":\"The specified virtualMachineImageId is in a different subscription and cannot be used with the current Batch account in subscription 3ee7eaf5-6a2f-49fd-953f-d760b5ac2e05\"\r\n }\r\n ]\r\n}", { 'content-length': '852',
.post('/pools?api-version=2018-12-01.8.0', '*')
.reply(400, "{\r\n \"odata.metadata\":\"https://test3.westcentralus.batch.azure.com/$metadata#Microsoft.Azure.Batch.Protocol.Entities.Container.errors/@Element\",\"code\":\"InvalidPropertyValue\",\"message\":{\r\n \"lang\":\"en-US\",\"value\":\"The value provided for one of the properties in the request body is invalid.\\nRequestId:55bccad4-65eb-464a-b9db-73ce5fe322ca\\nTime:2018-12-11T18:35:45.1020145Z\"\r\n },\"values\":[\r\n {\r\n \"key\":\"PropertyName\",\"value\":\"virtualMachineImageId\"\r\n },{\r\n \"key\":\"PropertyValue\",\"value\":\"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test/providers/Microsoft.Compute/images/FakeImage\"\r\n },{\r\n \"key\":\"Reason\",\"value\":\"The specified virtualMachineImageId is in a different subscription and cannot be used with the current Batch account in subscription f30ef677-64a9-4768-934f-5fbbc0e1ad27\"\r\n }\r\n ]\r\n}", { 'content-length': '849',
'content-type': 'application/json;odata=minimalmetadata',
server: 'Microsoft-HTTPAPI/2.0',
'request-id': '14df0f7d-179f-488c-942f-9ec1b6d12e5c',
'request-id': '55bccad4-65eb-464a-b9db-73ce5fe322ca',
'strict-transport-security': 'max-age=31536000; includeSubDomains',
'x-content-type-options': 'nosniff',
dataserviceversion: '3.0',
date: 'Tue, 21 Aug 2018 20:16:22 GMT',
date: 'Tue, 11 Dec 2018 18:35:45 GMT',
connection: 'close' });
return result; }]];
Loading

0 comments on commit 59b0457

Please sign in to comment.