-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[billing] Update billing projects to use snippets extraction
- Loading branch information
1 parent
7166a7a
commit 5e641ed
Showing
4 changed files
with
74 additions
and
41 deletions.
There are no files selected for viewing
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
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
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
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,27 @@ | ||
// Copyright (c) Microsoft Corporation. | ||
// Licensed under the MIT License. | ||
|
||
import { BillingManagementClient } from "../src/index.js"; | ||
import { DefaultAzureCredential, InteractiveBrowserCredential } from "@azure/identity"; | ||
import { setLogLevel } from "@azure/logger"; | ||
import { describe, it } from "vitest"; | ||
|
||
describe("snippets", () => { | ||
it("ReadmeSampleCreateClient_Node", async () => { | ||
const subscriptionId = "00000000-0000-0000-0000-000000000000"; | ||
const client = new BillingManagementClient(new DefaultAzureCredential(), subscriptionId); | ||
}); | ||
|
||
it("ReadmeSampleCreateClient_Browser", async () => { | ||
const subscriptionId = "00000000-0000-0000-0000-000000000000"; | ||
const credential = new InteractiveBrowserCredential({ | ||
tenantId: "<YOUR_TENANT_ID>", | ||
clientId: "<YOUR_CLIENT_ID>", | ||
}); | ||
const client = new BillingManagementClient(credential, subscriptionId); | ||
}); | ||
|
||
it("SetLogLevel", async () => { | ||
setLogLevel("info"); | ||
}); | ||
}); |