Update rnstorybook-config.test.ts

This commit is contained in:
Michael Shilman 2025-03-24 23:17:01 +08:00
parent f1a3442201
commit 612ffb1a9e

View File

@ -25,6 +25,7 @@ vi.mock('globby');
describe('react-native-config fix', () => { describe('react-native-config fix', () => {
beforeEach(() => { beforeEach(() => {
vi.mocked($).mockClear(); vi.mocked($).mockClear();
// @ts-expect-error blah
vi.mocked($).mockResolvedValue({ stdout: '' }); vi.mocked($).mockResolvedValue({ stdout: '' });
vi.mocked(globby).mockResolvedValue(['storybook.requires.ts']); vi.mocked(globby).mockResolvedValue(['storybook.requires.ts']);
}); });
@ -129,6 +130,7 @@ describe('react-native-config fix', () => {
}); });
it('when there are references to .storybook in the project', async () => { it('when there are references to .storybook in the project', async () => {
// @ts-expect-error blah
vi.mocked($).mockResolvedValue({ stdout: 'a\nb\nc' }); vi.mocked($).mockResolvedValue({ stdout: 'a\nb\nc' });
const packageManager = makePackageManager({ const packageManager = makePackageManager({
devDependencies: { devDependencies: {