Skip to content

Commit 41ec560

Browse files
authored
build(dev-deps): bump vitest to v4 (#100)
1 parent 6cc0f25 commit 41ec560

3 files changed

Lines changed: 134 additions & 244 deletions

File tree

__tests__/index.test.ts

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -32,16 +32,18 @@ vi.mocked(appCredentialsFromString).mockReturnValue({
3232
const getAuthenticated = vi.fn();
3333
const getByUsername = vi.fn();
3434

35-
vi.mocked(GitHub).mockReturnValue({
36-
rest: {
37-
apps: {
38-
getAuthenticated
39-
},
40-
users: {
41-
getByUsername
42-
}
43-
}
44-
} as any); // eslint-disable-line @typescript-eslint/no-explicit-any
35+
vi.mocked(GitHub).mockImplementation(
36+
class {
37+
rest = {
38+
apps: {
39+
getAuthenticated
40+
},
41+
users: {
42+
getByUsername
43+
}
44+
};
45+
} as unknown as typeof GitHub
46+
);
4547

4648
// Spy the action's entrypoint
4749
const runSpy = vi.spyOn(index, 'run');

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
"@types/node": "^20.5.6",
3838
"@typescript-eslint/eslint-plugin": "^6.4.1",
3939
"@typescript-eslint/parser": "^6.4.1",
40-
"@vitest/coverage-v8": "^3.0.5",
40+
"@vitest/coverage-v8": "^4.0.5",
4141
"esbuild": "^0.25.0",
4242
"eslint": "^8.48.0",
4343
"eslint-plugin-github": "^4.9.2",
@@ -49,7 +49,7 @@
4949
"prettier": "^3.0.2",
5050
"prettier-eslint": "^15.0.1",
5151
"typescript": "^5.2.2",
52-
"vitest": "^3.0.5"
52+
"vitest": "^4.0.5"
5353
},
5454
"packageManager": "yarn@4.10.3+sha512.c38cafb5c7bb273f3926d04e55e1d8c9dfa7d9c3ea1f36a4868fa028b9e5f72298f0b7f401ad5eb921749eb012eb1c3bb74bf7503df3ee43fd600d14a018266f"
5555
}

0 commit comments

Comments
 (0)