diff --git a/sdk/batch/batch/test/batchClient.spec.ts b/sdk/batch/batch/test/batchClient.spec.ts index 2effe6c49774..bb56111aa325 100644 --- a/sdk/batch/batch/test/batchClient.spec.ts +++ b/sdk/batch/batch/test/batchClient.spec.ts @@ -215,41 +215,41 @@ describe("Batch Service", () => { assert.equal(result._response.status, 200); }); - it.skip("should perform AAD authentication successfully", (done) => { - const verifyAadAuth = function(token: string, callback: any) { - const tokenCreds = new TokenCredentials(token, "Bearer"); - const aadClient = new BatchServiceClient(tokenCreds, batchEndpoint); - aadClient.account.listSupportedImages(function(err, result, request, response) { - assert.isNull(err); - assert.isDefined(result); - assert.isAtLeast(result!.length, 1); - assert.equal(response!.status, 200); - assert.isDefined(request!.headers.get("authorization")); - assert.equal(request!.headers.get("authorization"), "Bearer " + token); - callback(); - }); - }; - - // if (!suite.isPlayback) { - // const authContext = new AuthenticationContext( - // "https://login.microsoftonline.com/microsoft.onmicrosoft.com" - // ); - - // authContext.acquireTokenWithClientCredentials( - // "https://batch.core.windows.net/", - // clientId, - // secret, - // function(err: any, tokenResponse: TokenResponse) { - // assert.isNull(err); - // assert.isDefined(tokenResponse); - // assert.isDefined((tokenResponse as TokenResponse).accessToken); - // verifyAadAuth((tokenResponse as TokenResponse).accessToken, done); - // } - // ); - // } else { - verifyAadAuth("dummy token", done); - // } - }); + // it("should perform AAD authentication successfully", (done) => { + // const verifyAadAuth = function(token: string, callback: any) { + // const tokenCreds = new TokenCredentials(token, "Bearer"); + // const aadClient = new BatchServiceClient(tokenCreds, batchEndpoint); + // aadClient.account.listSupportedImages(function(err, result, request, response) { + // assert.isNull(err); + // assert.isDefined(result); + // assert.isAtLeast(result!.length, 1); + // assert.equal(response!.status, 200); + // assert.isDefined(request!.headers.get("authorization")); + // assert.equal(request!.headers.get("authorization"), "Bearer " + token); + // callback(); + // }); + // }; + + // // if (!suite.isPlayback) { + // // const authContext = new AuthenticationContext( + // // "https://login.microsoftonline.com/microsoft.onmicrosoft.com" + // // ); + + // // authContext.acquireTokenWithClientCredentials( + // // "https://batch.core.windows.net/", + // // clientId, + // // secret, + // // function(err: any, tokenResponse: TokenResponse) { + // // assert.isNull(err); + // // assert.isDefined(tokenResponse); + // // assert.isDefined((tokenResponse as TokenResponse).accessToken); + // // verifyAadAuth((tokenResponse as TokenResponse).accessToken, done); + // // } + // // ); + // // } else { + // verifyAadAuth("dummy token", done); + // // } + // }); it("should add a pool with vnet and get expected error", async () => { const pool: BatchServiceModels.PoolAddParameter = { @@ -1025,19 +1025,19 @@ describe("Batch Service", () => { }); }); - describe("Applications", async () => { - // the application is not added by the tests and should be added by the tester manually - it.skip("should list applications successfully", async () => { - const result = await client.application.list(); + // describe("Applications", async () => { + // // the application is not added by the tests and should be added by the tester manually + // it("should list applications successfully", async () => { + // const result = await client.application.list(); - assert.isAtLeast(result.length, 1); - assert.equal(result._response.status, 200); - }); + // assert.isAtLeast(result.length, 1); + // assert.equal(result._response.status, 200); + // }); - it.skip("should get application reference successfully", async () => { - await client.application.get("my_application_id"); - }); - }); + // it("should get application reference successfully", async () => { + // await client.application.get("my_application_id"); + // }); + // }); describe("Task cleanup", async () => { it("should delete a task successfully", async () => {