• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

safe-global / safe-client-gateway / 8630594257

10 Apr 2024 11:38AM UTC coverage: 45.232% (-47.6%) from 92.862%
8630594257

Pull #1369

github

iamacook
Only store signer address in JWT payload
Pull Request #1369: Add `AuthGuard`

293 of 2225 branches covered (13.17%)

Branch coverage included in aggregate %.

4 of 9 new or added lines in 3 files covered. (44.44%)

2495 existing lines in 237 files now uncovered.

3540 of 6249 relevant lines covered (56.65%)

8.62 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

85.71
/src/routes/cache-hooks/cache-hooks.controller.ts
1
import {
14✔
2
  Body,
3
  Controller,
4
  HttpCode,
5
  Inject,
6
  Post,
7
  UseGuards,
8
} from '@nestjs/common';
9
import { ApiExcludeController } from '@nestjs/swagger';
14✔
10
import { CacheHooksService } from '@/routes/cache-hooks/cache-hooks.service';
14✔
11
import { ValidationPipe } from '@/validation/pipes/validation.pipe';
14✔
12
import { BasicAuthGuard } from '@/routes/common/auth/basic-auth.guard';
14✔
13
import { Event } from '@/routes/cache-hooks/entities/event.entity';
14
import { PreExecutionLogGuard } from '@/routes/cache-hooks/guards/pre-execution.guard';
14✔
15
import { WebHookSchema } from '@/routes/cache-hooks/entities/schemas/web-hook.schema';
14✔
16
import { ILoggingService, LoggingService } from '@/logging/logging.interface';
14✔
17

18
@Controller({
19
  path: '',
20
  version: '1',
21
})
22
@ApiExcludeController()
23
export class CacheHooksController {
14✔
24
  constructor(
25
    private readonly service: CacheHooksService,
14✔
26
    @Inject(LoggingService) private readonly loggingService: ILoggingService,
14✔
27
  ) {}
28

29
  @UseGuards(PreExecutionLogGuard, BasicAuthGuard)
30
  @Post('/hooks/events')
31
  @HttpCode(202)
32
  async postEvent(
14✔
33
    @Body(new ValidationPipe(WebHookSchema)) event: Event,
34
  ): Promise<void> {
UNCOV
35
    this.service.onEvent(event).catch((error) => {
×
36
      this.loggingService.error(error);
×
37
    });
38
  }
39
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc