Skip to content

Commit

Permalink
Add missing samples
Browse files Browse the repository at this point in the history
  • Loading branch information
xirzec authored Dec 31, 2024
1 parent 27d363d commit 815b816
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 27 deletions.
2 changes: 1 addition & 1 deletion eng/tools/rush-runner/test/helpers.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { assert, describe, it } from "vitest";
import { getDirectionMappedPackages, reducedDependencyTestMatrix } from "../helpers.js";

describe("getDirectionMappedPackages", () => {
it("should use --to reduced core scope for changed core package", () => {
it.only("should use --to reduced core scope for changed core package", () => {
const changed = ["@azure/core-client"];
const mapped = getDirectionMappedPackages(changed, ["unit-test"]);

Expand Down
Original file line number Diff line number Diff line change
@@ -1,17 +1,6 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.

/**
* @summary Publish and Receive events to Event Grid.
*/

const { EventGridSenderClient, EventGridReceiverClient } = require("@azure/eventgrid-namespaces");
const { AzureKeyCredential } = require("@azure/core-auth");

const dotenv = require("dotenv");

// Load the .env file if it exists
dotenv.config();
require("dotenv/config");

const endpoint = process.env["EVENT_GRID_NAMESPACES_ENDPOINT"] ?? "https://endpoint";
const key = process.env["EVENT_GRID_NAMESPACES_KEY"] ?? "api_key";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,6 @@
"dependencies": {
"@azure/eventgrid-namespaces": "latest",
"dotenv": "latest",
"@azure/core-auth": "^1.7.0"
"@azure/core-auth": "^1.9.0"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,11 @@
"dependencies": {
"@azure/eventgrid-namespaces": "latest",
"dotenv": "latest",
"@azure/core-auth": "^1.7.0"
"@azure/core-auth": "^1.9.0"
},
"devDependencies": {
"@types/node": "^18.0.0",
"typescript": "~5.7.2",
"typescript": "~5.6.2",
"rimraf": "latest"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,10 @@
* @summary Publish and Receive events to Event Grid.
*/

import {
EventGridSenderClient,
EventGridReceiverClient,
CloudEvent,
ReceiveResult,
} from "@azure/eventgrid-namespaces";
import type { CloudEvent, ReceiveResult } from "@azure/eventgrid-namespaces";
import { EventGridSenderClient, EventGridReceiverClient } from "@azure/eventgrid-namespaces";
import { AzureKeyCredential } from "@azure/core-auth";

import * as dotenv from "dotenv";

// Load the .env file if it exists
dotenv.config();
import "dotenv/config";

const endpoint = process.env["EVENT_GRID_NAMESPACES_ENDPOINT"] ?? "https://endpoint";
const key = process.env["EVENT_GRID_NAMESPACES_KEY"] ?? "api_key";
Expand Down

0 comments on commit 815b816

Please sign in to comment.