From 5a52847560fd8ec22dbf4768702f0e8f0fde5b71 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20I=C3=9Fmer?= Date: Mon, 22 Aug 2022 13:42:34 +0200 Subject: [PATCH] build: fix types for test context --- test/prepare.test.ts | 3 ++- test/publish.test.ts | 3 ++- test/verify.test.ts | 3 ++- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/test/prepare.test.ts b/test/prepare.test.ts index c54f62de..bc6840b5 100644 --- a/test/prepare.test.ts +++ b/test/prepare.test.ts @@ -11,8 +11,9 @@ describe("prepare", () => { beforeAll(() => { const logMock = jest.fn(); context = { + branch: { name: "main" }, env: {}, - logger: { log: logMock, error: logMock }, + logger: { log: logMock, error: logMock } as any, nextRelease: { gitTag: "v1.0.0", notes: "", type: "major", gitHead: "", version: "1.0.0" }, }; }); diff --git a/test/publish.test.ts b/test/publish.test.ts index 9ded7e25..e5fae0d0 100644 --- a/test/publish.test.ts +++ b/test/publish.test.ts @@ -11,8 +11,9 @@ describe("publish", () => { beforeAll(() => { const logMock = jest.fn(); context = { + branch: { name: "main" }, env: {}, - logger: { log: logMock, error: logMock }, + logger: { log: logMock, error: logMock } as any, nextRelease: { gitTag: "v1.0.0", notes: "", type: "major", gitHead: "", version: "1.0.0" }, }; execaMock = execa as unknown as jest.Mock, never[]>; diff --git a/test/verify.test.ts b/test/verify.test.ts index e8f21249..2b0b4f98 100644 --- a/test/verify.test.ts +++ b/test/verify.test.ts @@ -16,8 +16,9 @@ describe("verify", () => { originalEnv = process.env; const logMock = jest.fn(); context = { + branch: { name: "main" }, env: {}, - logger: { log: logMock, error: logMock }, + logger: { log: logMock, error: logMock } as any, nextRelease: { gitTag: "v1.0.0", notes: "", type: "major", gitHead: "", version: "1.0.0" }, }; execaMock = execa as unknown as jest.Mock, unknown[]>;