Skip to content

Commit 4488637

Browse files
committed
Skip express v5 tests for Node v14
1 parent 28a9fd0 commit 4488637

File tree

4 files changed

+24
-0
lines changed

4 files changed

+24
-0
lines changed

plugins/node/opentelemetry-instrumentation-express/test/v5/custom-config.test.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,12 @@ import {
3232
} from '../../src';
3333
import { createServer, httpRequest } from './utils';
3434

35+
const nodeVersionNotSupported = process.version.startsWith('14');
36+
if (nodeVersionNotSupported) {
37+
console.log('Skipping express v5 tests for node version 14');
38+
process.exit(0);
39+
}
40+
3541
const instrumentation = new ExpressInstrumentation({
3642
ignoreLayersType: [ExpressLayerType.MIDDLEWARE],
3743
});

plugins/node/opentelemetry-instrumentation-express/test/v5/express.test.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,12 @@ import { createServer, httpRequest, serverWithMiddleware } from './utils';
2828
import { SEMATTRS_HTTP_ROUTE } from '@opentelemetry/semantic-conventions';
2929
import * as testUtils from '@opentelemetry/contrib-test-utils';
3030

31+
const nodeVersionNotSupported = process.version.startsWith('14');
32+
if (nodeVersionNotSupported) {
33+
console.log('Skipping express v5 tests for node version 14');
34+
process.exit(0);
35+
}
36+
3137
const instrumentation = new ExpressInstrumentation();
3238
instrumentation.enable();
3339
instrumentation.disable();

plugins/node/opentelemetry-instrumentation-express/test/v5/hooks.test.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,12 @@ import { ExpressRequestInfo, SpanNameHook } from '../../src/types';
2929
import { ExpressLayerType } from '../../src/enums/ExpressLayerType';
3030
import { SEMATTRS_HTTP_METHOD } from '@opentelemetry/semantic-conventions';
3131

32+
const nodeVersionNotSupported = process.version.startsWith('14');
33+
if (nodeVersionNotSupported) {
34+
console.log('Skipping express v5 tests for node version 14');
35+
process.exit(0);
36+
}
37+
3238
const instrumentation = new ExpressInstrumentation();
3339
instrumentation.enable();
3440
instrumentation.disable();

plugins/node/opentelemetry-instrumentation-express/test/v5/ignore-all.test.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,12 @@ import { AttributeNames } from '../../src/enums/AttributeNames';
2727
import { ExpressInstrumentation, ExpressLayerType } from '../../src';
2828
import { createServer, httpRequest } from './utils';
2929

30+
const nodeVersionNotSupported = process.version.startsWith('14');
31+
if (nodeVersionNotSupported) {
32+
console.log('Skipping express v5 tests for node version 14');
33+
process.exit(0);
34+
}
35+
3036
const instrumentation = new ExpressInstrumentation({
3137
ignoreLayersType: [
3238
ExpressLayerType.MIDDLEWARE,

0 commit comments

Comments
 (0)