Skip to content

Commit cb37ecb

Browse files
test(): remove deprecated methods usage, bump kafka timeout
1 parent c7dce66 commit cb37ecb

13 files changed

Lines changed: 17 additions & 17 deletions

integration/microservices/e2e/broadcast-mqtt.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ describe('MQTT transport', () => {
2828
host: '0.0.0.0',
2929
},
3030
});
31-
await app.startAllMicroservicesAsync();
31+
await app.startAllMicroservices();
3232
await app.init();
3333
});
3434

integration/microservices/e2e/broadcast-nats.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ describe('NATS transport', () => {
2828
url: 'nats://0.0.0.0:4222',
2929
},
3030
});
31-
await app.startAllMicroservicesAsync();
31+
await app.startAllMicroservices();
3232
await app.init();
3333
});
3434

integration/microservices/e2e/broadcast-redis.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ describe('REDIS transport', () => {
2828
url: 'redis://0.0.0.0:6379',
2929
},
3030
});
31-
await app.startAllMicroservicesAsync();
31+
await app.startAllMicroservices();
3232
await app.init();
3333
});
3434

integration/microservices/e2e/concurrent-kafka.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ describe('Kafka concurrent', function () {
5757
apps.push(app);
5858

5959
// await the start
60-
await app.startAllMicroservicesAsync();
60+
await app.startAllMicroservices();
6161
await app.init();
6262
};
6363

integration/microservices/e2e/orders-grpc.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import * as GRPC from '@grpc/grpc-js';
12
import * as ProtoLoader from '@grpc/proto-loader';
23
import { INestApplication } from '@nestjs/common';
34
import { Transport } from '@nestjs/microservices';
@@ -6,7 +7,6 @@ import { Test } from '@nestjs/testing';
67
import { fail } from 'assert';
78
import { expect } from 'chai';
89
import * as express from 'express';
9-
import * as GRPC from '@grpc/grpc-js';
1010
import { join } from 'path';
1111
import * as request from 'supertest';
1212
import { AdvancedGrpcController } from '../src/grpc-advanced/advanced.grpc.controller';
@@ -39,7 +39,7 @@ describe('Advanced GRPC transport', () => {
3939
},
4040
});
4141
// Start gRPC microservice
42-
await app.startAllMicroservicesAsync();
42+
await app.startAllMicroservices();
4343
await app.init();
4444
// Load proto-buffers for test gRPC dispatch
4545
const proto = ProtoLoader.loadSync('root.proto', {

integration/microservices/e2e/sum-grpc.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1+
import * as GRPC from '@grpc/grpc-js';
12
import * as ProtoLoader from '@grpc/proto-loader';
23
import { INestApplication } from '@nestjs/common';
34
import { Transport } from '@nestjs/microservices';
45
import { Test } from '@nestjs/testing';
56
import { fail } from 'assert';
67
import { expect } from 'chai';
7-
import * as GRPC from '@grpc/grpc-js';
88
import { join } from 'path';
99
import * as request from 'supertest';
1010
import { GrpcController } from '../src/grpc/grpc.controller';
@@ -33,7 +33,7 @@ describe('GRPC transport', () => {
3333
},
3434
});
3535
// Start gRPC microservice
36-
await app.startAllMicroservicesAsync();
36+
await app.startAllMicroservices();
3737
await app.init();
3838
// Load proto-buffers for test gRPC dispatch
3939
const proto = ProtoLoader.loadSync(

integration/microservices/e2e/sum-kafka.spec.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ describe('Kafka transport', function () {
1414
let app: INestApplication;
1515

1616
// set timeout to be longer (especially for the after hook)
17-
this.timeout(30000);
17+
this.timeout(50000);
1818

1919
it(`Start Kafka app`, async () => {
2020
const module = await Test.createTestingModule({
@@ -33,7 +33,7 @@ describe('Kafka transport', function () {
3333
},
3434
});
3535
app.enableShutdownHooks();
36-
await app.startAllMicroservicesAsync();
36+
await app.startAllMicroservices();
3737
await app.init();
3838
}).timeout(30000);
3939

@@ -130,4 +130,4 @@ describe('Kafka transport', function () {
130130
after(`Stopping Kafka app`, async () => {
131131
await app.close();
132132
});
133-
}).timeout(30000);
133+
}).timeout(50000);

integration/microservices/e2e/sum-mqtt.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ describe('MQTT transport', () => {
2323
url: 'mqtt://0.0.0.0:1883',
2424
},
2525
});
26-
await app.startAllMicroservicesAsync();
26+
await app.startAllMicroservices();
2727
await app.init();
2828
});
2929

integration/microservices/e2e/sum-nats.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ describe('NATS transport', () => {
2323
url: 'nats://0.0.0.0:4222',
2424
},
2525
});
26-
await app.startAllMicroservicesAsync();
26+
await app.startAllMicroservices();
2727
await app.init();
2828
});
2929

integration/microservices/e2e/sum-redis.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ describe('REDIS transport', () => {
2323
url: 'redis://0.0.0.0:6379',
2424
},
2525
});
26-
await app.startAllMicroservicesAsync();
26+
await app.startAllMicroservices();
2727
await app.init();
2828
});
2929

0 commit comments

Comments
 (0)