From 9bea2b1856299bf6edb104c9f366d57c7e20fe01 Mon Sep 17 00:00:00 2001 From: tudor <7089284+tudddorrr@users.noreply.github.com> Date: Sat, 27 Apr 2024 21:42:00 +0100 Subject: [PATCH] update references from c8 to v8 --- .github/workflows/ci.yml | 2 +- src/entities/game-activity.ts | 4 ++-- src/entities/game-secret.ts | 4 ++-- src/middlewares/tracing-middleware.ts | 2 +- src/services/data-export.service.ts | 6 +++--- src/services/public/demo.service.ts | 2 +- src/services/public/user-public.service.ts | 4 ++-- src/services/public/webhook.service.ts | 4 ++-- 8 files changed, 14 insertions(+), 14 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 37fb4ccd..663f8f95 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -24,7 +24,7 @@ jobs: run: cp envs/.env.dev .env - name: Run tests - run: npm test --coverage + run: npm test -- --coverage - uses: codecov/codecov-action@v4 with: diff --git a/src/entities/game-activity.ts b/src/entities/game-activity.ts index f2d0d5cd..8a498e6f 100644 --- a/src/entities/game-activity.ts +++ b/src/entities/game-activity.ts @@ -59,7 +59,7 @@ export default class GameActivity { this.user = user } - /* c8 ignore start */ + /* v8 ignore start */ private getActivity(): string { switch (this.type) { case GameActivityType.PLAYER_PROPS_UPDATED: @@ -112,7 +112,7 @@ export default class GameActivity { return '' } } - /* c8 ignore stop */ + /* v8 ignore stop */ toJSON() { return { diff --git a/src/entities/game-secret.ts b/src/entities/game-secret.ts index 46854792..9b9dc1eb 100644 --- a/src/entities/game-secret.ts +++ b/src/entities/game-secret.ts @@ -27,11 +27,11 @@ export default class GameSecret { return decrypt(this.secret, process.env.API_SECRET) } - /* c8 ignore start */ + /* v8 ignore start */ toJSON() { return { id: this.id } } - /* c8 ignore stop */ + /* v8 ignore stop */ } diff --git a/src/middlewares/tracing-middleware.ts b/src/middlewares/tracing-middleware.ts index da76357d..eccd5d17 100644 --- a/src/middlewares/tracing-middleware.ts +++ b/src/middlewares/tracing-middleware.ts @@ -8,7 +8,7 @@ export default async (ctx: Context, next: Next) => { // connect to trace of upstream app let traceparentData - /* c8 ignore next 3 */ + /* v8 ignore next 3 */ if (ctx.request.get('sentry-trace')) { traceparentData = Sentry.extractTraceparentData(ctx.request.get('sentry-trace')) } diff --git a/src/services/data-export.service.ts b/src/services/data-export.service.ts index 2ee38400..b61f694d 100644 --- a/src/services/data-export.service.ts +++ b/src/services/data-export.service.ts @@ -107,13 +107,13 @@ export default class DataExportService extends Service { ]), { dataExportId }) await unlink(filepath) - /* c8 ignore start */ + /* v8 ignore start */ }, { failed: async (job: Job) => { await this.updateDataExportStatus(job.data.dataExportId, { failedAt: new Date() }) } }) - /* c8 ignore stop */ + /* v8 ignore stop */ } private async updateDataExportStatus(dataExportId: number, newStatus: UpdatedDataExportStatus): Promise { @@ -189,7 +189,7 @@ export default class DataExportService extends Service { const stats = await em.getRepository(GameStat).find({ game: dataExport.game }) for (const stat of stats) { - /* c8 ignore next 3 */ + /* v8 ignore next 3 */ if (stat.global) { await stat.recalculateGlobalValue(includeDevData) } diff --git a/src/services/public/demo.service.ts b/src/services/public/demo.service.ts index a31e6dc0..54ac1ae8 100644 --- a/src/services/public/demo.service.ts +++ b/src/services/public/demo.service.ts @@ -18,7 +18,7 @@ interface DemoUserJob { } async function scheduleDeletion(req: Request, res: Response, caller: DemoService): Promise { - /* c8 ignore next 3 */ + /* v8 ignore next 3 */ if (res.status === 200) { await caller.queue.add('demo-user', { userId: res.body.user.id }, { delay: 3600000 }) } diff --git a/src/services/public/user-public.service.ts b/src/services/public/user-public.service.ts index b218f876..8606a9fc 100644 --- a/src/services/public/user-public.service.ts +++ b/src/services/public/user-public.service.ts @@ -27,7 +27,7 @@ import ResetPassword from '../../emails/reset-password' async function sendEmailConfirm(req: Request, res: Response): Promise { const user: User = req.ctx.state.user - /* c8 ignore start */ + /* v8 ignore start */ if (res.status === 200 && !user.emailConfirmed) { const em: EntityManager = req.ctx.em @@ -36,7 +36,7 @@ async function sendEmailConfirm(req: Request, res: Response): Promise { await queueEmail(req.ctx.emailQueue, new ConfirmEmail(user, accessCode.code)) } - /* c8 ignore stop */ + /* v8 ignore stop */ } @Routes([ diff --git a/src/services/public/webhook.service.ts b/src/services/public/webhook.service.ts index f6c83aeb..d4942e80 100644 --- a/src/services/public/webhook.service.ts +++ b/src/services/public/webhook.service.ts @@ -101,12 +101,12 @@ export default class WebhookService extends Service { req.headers['stripe-signature'], process.env.STRIPE_WEBHOOK_SECRET ) - /* c8 ignore start */ + /* v8 ignore start */ } catch (err) { Sentry.captureException(err) req.ctx.throw(401) } - /* c8 ignore stop */ + /* v8 ignore stop */ switch (event.type) { case 'customer.subscription.deleted':