Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
Ankcorn committed Oct 19, 2023
1 parent 1697ba6 commit 3b35d9a
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions tests/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@ describe("Test BaselimeSDK for opentelemetry", async () => {
collectorUrl: mockServer.url,
serverless: true,
baselimeKey: baselimeKey,
service: "my_service",
namespace: "my_namespace"
})

sdk.start();
Expand All @@ -35,12 +33,6 @@ describe("Test BaselimeSDK for opentelemetry", async () => {
const [request] = await waitForCollector(collector)

expect(request.headers["x-api-key"]).toBe(baselimeKey);


const { resourceSpans: [serialisedSpan]} = getSpans(request)

console.log(JSON.stringify(serialisedSpan, null, 2))
expect(serialisedSpan.resource.attributes.find((attr) => attr.key === "$baselime.service")?.value.stringValue).toBe("my_service");
expect(serialisedSpan.resource.attributes.find((attr) => attr.key === "$baselime.namespace")?.value.stringValue).toBe("my_namespace")

})
});

0 comments on commit 3b35d9a

Please sign in to comment.