diff --git a/.circleci/config.yml b/.circleci/config.yml index 3f219e68c6..a280fde28d 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -3,7 +3,7 @@ version: 2 references: container_config: &container_config docker: - - image: circleci/node:8 + - image: circleci/node:lts working_directory: ~/ant-design attach_workspace: &attach_workspace diff --git a/components/anchor/__tests__/Anchor.test.js b/components/anchor/__tests__/Anchor.test.js index 65be9cfa2e..3cf43c755c 100644 --- a/components/anchor/__tests__/Anchor.test.js +++ b/components/anchor/__tests__/Anchor.test.js @@ -279,10 +279,13 @@ describe('Anchor Render', () => { let dateNowMock; function dataNowMockFn() { - return jest - .spyOn(Date, 'now') - .mockImplementationOnce(() => 0) - .mockImplementationOnce(() => 1000); + let start = 0; + + const handler = () => { + return (start += 1000); + }; + + return jest.spyOn(Date, 'now').mockImplementation(handler); } dateNowMock = dataNowMockFn();