diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f6e6ea2d5..d57b6260d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -26,14 +26,14 @@ jobs: uses: actions/setup-node@v1 with: node-version: ${{ matrix.node-version }} + - name: Start Docker Compose + run: docker-compose up -d - name: install run: yarn setup - name: lint run: yarn lint - name: test run: yarn test:cov - - name: Start Docker Compose - run: docker-compose up -d - name: integration test run: yarn test:int - name: Stop Docker Compose diff --git a/integration/test/rpc.spec.ts b/integration/test/rpc.spec.ts index 333f4c3d8..bdb19d4d9 100644 --- a/integration/test/rpc.spec.ts +++ b/integration/test/rpc.spec.ts @@ -1,5 +1,12 @@ import { INestApplication, INestMicroservice } from '@nestjs/common'; -import { MicroserviceOptions, Transport } from '@nestjs/microservices'; +import { + MicroserviceOptions, + MqttOptions, + NatsOptions, + RmqOptions, + TcpOptions, + Transport, +} from '@nestjs/microservices'; import { Test } from '@nestjs/testing'; import { color } from '@ogma/logger'; import { @@ -21,15 +28,18 @@ import { serviceOptionsFactory, } from './utils'; -const tcpOptions = {}; -const mqttOptions = { url: 'mqtt://localhost:1883' }; -const natsOptions = { url: 'nats://localhost:4222' }; -const rabbitOptions = { +const tcpOptions: TcpOptions['options'] = {}; +const mqttOptions: MqttOptions['options'] = { url: 'mqtt://localhost:1883' }; +const natsOptions: NatsOptions['options'] = { url: 'nats://localhost:4222' }; +const rabbitOptions: RmqOptions['options'] = { urls: ['amqp://localhost:5672'], queue: 'cats_queue', queueOptions: { durable: false, }, + socketOptions: { + durable: true, + }, }; describe.each`