mirror of
https://github.com/hanzoai/jest.git
synced 2026-09-24 16:59:57 +00:00
15 lines
368 B
JavaScript
15 lines
368 B
JavaScript
// Copyright (c) Meta Platforms, Inc. and affiliates.. All Rights Reserved.
|
|
|
|
import defaultExport, {apple, strawberry} from '../fruit';
|
|
|
|
/**
|
|
* This file illustrates a full mock of a module.
|
|
*/
|
|
jest.mock('../fruit');
|
|
|
|
it('does a full mock', () => {
|
|
expect(defaultExport()).toBeUndefined();
|
|
expect(apple).toBe('apple');
|
|
expect(strawberry()).toBeUndefined();
|
|
});
|