Skip to content

Commit c99bda5

Browse files
author
SDKAuto
committed
CodeGen from PR 24715 in Azure/azure-rest-api-specs
Merge ae39505977ed1f7dcfd8dc6201f3f1efa994f02f into 8a56aa33078dad6012aa59653cbfa643fa985f15
1 parent 48e32d4 commit c99bda5

File tree

5 files changed

+60
-27
lines changed

5 files changed

+60
-27
lines changed
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
{
2-
"commit": "0f39a2d56070d2bc4251494525cb8af88583a938",
2+
"commit": "06f8fee01019be4e2849bdde240527c461736a26",
33
"readme": "specification/dataprotection/resource-manager/readme.md",
4-
"autorest_command": "autorest --version=3.9.3 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\dataprotection\\resource-manager\\readme.md --use=@autorest/[email protected].5 --generate-sample=true",
4+
"autorest_command": "autorest --version=3.9.3 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/dataprotection/resource-manager/readme.md --use=@autorest/typescript@^6.0.4",
55
"repository_url": "https://github.com/Azure/azure-rest-api-specs.git",
6-
"release_tool": "@azure-tools/[email protected].0",
7-
"use": "@autorest/[email protected].5"
6+
"release_tool": "@azure-tools/[email protected].1",
7+
"use": "@autorest/typescript@^6.0.4"
88
}

sdk/dataprotection/arm-dataprotection/package.json

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"node": ">=14.0.0"
99
},
1010
"dependencies": {
11-
"@azure/core-lro": "^2.5.3",
11+
"@azure/core-lro": "^2.5.4",
1212
"@azure/abort-controller": "^1.0.0",
1313
"@azure/core-paging": "^1.2.0",
1414
"@azure/core-client": "^1.7.0",
@@ -111,13 +111,5 @@
111111
]
112112
},
113113
"autoPublish": true,
114-
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/dataprotection/arm-dataprotection",
115-
"//sampleConfiguration": {
116-
"productName": "",
117-
"productSlugs": [
118-
"azure"
119-
],
120-
"disableDocsMs": true,
121-
"apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-dataprotection?view=azure-node-preview"
122-
}
123-
}
114+
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/dataprotection/arm-dataprotection"
115+
}

sdk/dataprotection/arm-dataprotection/src/operations/backupInstances.ts

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -448,7 +448,8 @@ export class BackupInstancesImpl implements BackupInstances {
448448
OperationState<BackupInstancesAdhocBackupResponse>
449449
>(lro, {
450450
restoreFrom: options?.resumeFrom,
451-
intervalInMs: options?.updateIntervalInMs
451+
intervalInMs: options?.updateIntervalInMs,
452+
resourceLocationConfig: "location"
452453
});
453454
await poller.poll();
454455
return poller;
@@ -546,7 +547,8 @@ export class BackupInstancesImpl implements BackupInstances {
546547
OperationState<BackupInstancesValidateForBackupResponse>
547548
>(lro, {
548549
restoreFrom: options?.resumeFrom,
549-
intervalInMs: options?.updateIntervalInMs
550+
intervalInMs: options?.updateIntervalInMs,
551+
resourceLocationConfig: "location"
550552
});
551553
await poller.poll();
552554
return poller;
@@ -782,7 +784,8 @@ export class BackupInstancesImpl implements BackupInstances {
782784
OperationState<BackupInstancesTriggerRestoreResponse>
783785
>(lro, {
784786
restoreFrom: options?.resumeFrom,
785-
intervalInMs: options?.updateIntervalInMs
787+
intervalInMs: options?.updateIntervalInMs,
788+
resourceLocationConfig: "location"
786789
});
787790
await poller.poll();
788791
return poller;
@@ -1338,7 +1341,8 @@ export class BackupInstancesImpl implements BackupInstances {
13381341
OperationState<BackupInstancesValidateForRestoreResponse>
13391342
>(lro, {
13401343
restoreFrom: options?.resumeFrom,
1341-
intervalInMs: options?.updateIntervalInMs
1344+
intervalInMs: options?.updateIntervalInMs,
1345+
resourceLocationConfig: "location"
13421346
});
13431347
await poller.poll();
13441348
return poller;
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
/*
2+
* Copyright (c) Microsoft Corporation.
3+
* Licensed under the MIT License.
4+
*
5+
* Code generated by Microsoft (R) AutoRest Code Generator.
6+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
7+
*/
8+
9+
import {
10+
Recorder,
11+
RecorderStartOptions,
12+
env
13+
} from "@azure-tools/test-recorder";
14+
import { assert } from "chai";
15+
import { Context } from "mocha";
16+
17+
const replaceableVariables: Record<string, string> = {
18+
AZURE_CLIENT_ID: "azure_client_id",
19+
AZURE_CLIENT_SECRET: "azure_client_secret",
20+
AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888",
21+
SUBSCRIPTION_ID: "azure_subscription_id"
22+
};
23+
24+
const recorderOptions: RecorderStartOptions = {
25+
envSetupForPlayback: replaceableVariables
26+
};
27+
28+
describe("My test", () => {
29+
let recorder: Recorder;
30+
31+
beforeEach(async function(this: Context) {
32+
recorder = new Recorder(this.currentTest);
33+
await recorder.start(recorderOptions);
34+
});
35+
36+
afterEach(async function() {
37+
await recorder.stop();
38+
});
39+
40+
it("sample test", async function() {
41+
console.log("Hi, I'm a test!");
42+
});
43+
});

sdk/dataprotection/arm-dataprotection/tsconfig.json

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -15,17 +15,11 @@
1515
],
1616
"declaration": true,
1717
"outDir": "./dist-esm",
18-
"importHelpers": true,
19-
"paths": {
20-
"@azure/arm-dataprotection": [
21-
"./src/index"
22-
]
23-
}
18+
"importHelpers": true
2419
},
2520
"include": [
2621
"./src/**/*.ts",
27-
"./test/**/*.ts",
28-
"samples-dev/**/*.ts"
22+
"./test/**/*.ts"
2923
],
3024
"exclude": [
3125
"node_modules"

0 commit comments

Comments
 (0)