Skip to content

Commit

Permalink
Make ESM test standalone
Browse files Browse the repository at this point in the history
  • Loading branch information
onurtemizkan committed Dec 6, 2024
1 parent 44e37ea commit ba9fafa
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,7 @@ describe('pg', () => {
if (testPostgresLocally) {
testUtils.cleanUpDocker('postgres');
}

await client.end();
});

Expand Down Expand Up @@ -1087,7 +1088,9 @@ describe('pg', () => {
});
});
});
});

describe('pg (ESM)', () => {
it('should work with ESM usage', async () => {
await testUtils.runTestFixture({
cwd: __dirname,
Expand All @@ -1109,7 +1112,7 @@ describe('pg', () => {
assert.strictEqual(spans[0].kind, 3);
assert.strictEqual(spans[1].name, 'test-span');
assert.strictEqual(spans[1].kind, 1);
assert.strictEqual(spans[2].name, 'pg.query:SELECT postgres');
assert.strictEqual(spans[2].name, 'pg.query:SELECT otel_pg_database');
assert.strictEqual(spans[2].kind, 3);
},
});
Expand Down

0 comments on commit ba9fafa

Please sign in to comment.