mirror of
https://github.com/Unleash/unleash.git
synced 2025-01-11 00:08:30 +01:00
9 lines
334 B
TypeScript
9 lines
334 B
TypeScript
|
import { formatUnknownError } from './format-unknown-error';
|
||
|
|
||
|
test('formatUnknownError', () => {
|
||
|
expect(formatUnknownError(1)).toEqual('Unknown error');
|
||
|
expect(formatUnknownError('1')).toEqual('1');
|
||
|
expect(formatUnknownError(new Error('1'))).toEqual('1');
|
||
|
expect(formatUnknownError(new Error())).toEqual('Error');
|
||
|
});
|