Skip to content

Commit 4f2e3f5

Browse files
chore(deps): bump @actions/core from 1.11.1 to 3.0.1 (#225)
* chore(deps): bump @actions/core from 1.11.1 to 3.0.1 Bumps [@actions/core](https://github.com/actions/toolkit/tree/HEAD/packages/core) from 1.11.1 to 3.0.1. - [Changelog](https://github.com/actions/toolkit/blob/main/packages/core/RELEASES.md) - [Commits](https://github.com/actions/toolkit/commits/HEAD/packages/core) --- updated-dependencies: - dependency-name: "@actions/core" dependency-version: 3.0.1 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> * chore(deps): bump @actions/exec from 1.1.1 to 3.0.0 Bumps [@actions/exec](https://github.com/actions/toolkit/tree/HEAD/packages/exec) from 1.1.1 to 3.0.0. - [Changelog](https://github.com/actions/toolkit/blob/main/packages/exec/RELEASES.md) - [Commits](https://github.com/actions/toolkit/commits/HEAD/packages/exec) --- updated-dependencies: - dependency-name: "@actions/exec" dependency-version: 3.0.0 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> * chore(deps): bump @actions/github from 6.0.0 to 9.1.1 Bumps [@actions/github](https://github.com/actions/toolkit/tree/HEAD/packages/github) from 6.0.0 to 9.1.1. - [Changelog](https://github.com/actions/toolkit/blob/main/packages/github/RELEASES.md) - [Commits](https://github.com/actions/toolkit/commits/HEAD/packages/github) --- updated-dependencies: - dependency-name: "@actions/github" dependency-version: 9.1.1 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> * test: mock @action/* esm imports * chore: update bundle dist --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Ryan Chang <ryancyq@gmail.com>
1 parent f7b0ed0 commit 4f2e3f5

5 files changed

Lines changed: 39555 additions & 20486 deletions

File tree

__tests__/setup.ts

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
import { vi } from 'vitest'
2+
3+
// @actions/* v3+ packages ship as true ESM, whose module namespace objects are non-configurable
4+
// by spec, making vi.spyOn fail with "Cannot redefine property". Spreading the real exports
5+
// into a plain object gives Vitest a configurable target so spyOn works while keeping the
6+
// original implementations for anything not explicitly mocked in a test.
7+
// See: https://vitest.dev/guide/mocking/modules.html#jsdom-happy-dom-node
8+
vi.mock('@actions/core', async (importOriginal) => {
9+
const actual = await importOriginal<typeof import('@actions/core')>()
10+
return { ...actual }
11+
})
12+
13+
vi.mock('@actions/exec', async (importOriginal) => {
14+
const actual = await importOriginal<typeof import('@actions/exec')>()
15+
return { ...actual }
16+
})

0 commit comments

Comments
 (0)