Skip to content

Commit

Permalink
small test fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
tmthecoder committed Nov 19, 2024
1 parent 96113b4 commit 9914753
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ export class FileDownloadController implements OnModuleInit {
);
}

@Post('file')
@Post('download')
@ApiOperation({ summary: 'Downloads a file' })
@ApiResponse({
status: HttpStatus.BAD_REQUEST,
Expand Down
4 changes: 3 additions & 1 deletion packages/api-gateway/test/file_download.e2e-spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import {
} from 'juno-proto';
import * as GRPC from '@grpc/grpc-js';
import * as ProtoLoader from '@grpc/proto-loader';
import { RpcExceptionFilter } from 'src/rpc_exception_filter';

let app: INestApplication;
const ADMIN_EMAIL = '[email protected]';
Expand Down Expand Up @@ -151,6 +152,7 @@ beforeEach(async () => {
}),
);
app.useGlobalInterceptors(new ClassSerializerInterceptor(app.get(Reflector)));
app.useGlobalFilters(new RpcExceptionFilter());

await app.init();

Expand All @@ -172,7 +174,7 @@ describe('File Download Verification Routes', () => {
.post('/file/download')
.set('Authorization', 'Bearer ' + apiKey)
.send(req)
.expect(200);
.expect(201);
});
it('downloads file without api key', async () => {
const req = {
Expand Down

0 comments on commit 9914753

Please sign in to comment.