2020-04-20 22:33:15 +08:00
|
|
|
import isCancel from '../../src/cancel/isCancel';
|
|
|
|
import Cancel from '../../src/cancel/Cancel';
|
|
|
|
|
|
|
|
describe('测试 src/cancel/isCancel', () => {
|
|
|
|
it('是一个取消?', () => {
|
2020-04-21 10:02:11 +08:00
|
|
|
const cancel1 = {};
|
2020-04-20 22:33:15 +08:00
|
|
|
const cancel2 = new Cancel();
|
|
|
|
|
|
|
|
expect(isCancel(cancel1)).toBe(false);
|
|
|
|
expect(isCancel(cancel2)).toBe(true);
|
|
|
|
});
|
|
|
|
});
|