-
-
Notifications
You must be signed in to change notification settings - Fork 827
Open
Labels
Feature: Want this? Upvote it!This PR or Issue may be a great consideration for a future idea.This PR or Issue may be a great consideration for a future idea.
Description
Prerequisites
- I have read the Contributing Guidelines.
- I agree to follow the Code of Conduct.
- I have searched for existing issues that already include this feature request, without success.
Describe the Feature Request
For test purpose we need to fake the current date.
Describe the Use Case
For test purpose we need to fake the current date.
We work on a calendar component and use screenshot tests.
Sadly each time we run test and the current date changed, the component will render differently and it's expected.
It's why we need to fixe a date to run a test on it.
We tested :
- to proxy the Date object in the browser without success.
- to use
jest.useFakeTimers('modern').setSystemTime(…)but we encounter a bunch of Timeout errors in e2e tests
Describe Preferred Solution
Don't have a preference :
- parameter in
newE2ePageto set a date as "now" - a way to reach the puppeteer
browserbefore to run a page
Describe Alternatives
No response
Related Code
No response
Additional Information
No response
gearsdigital, mcgraphix and womblep
Metadata
Metadata
Assignees
Labels
Feature: Want this? Upvote it!This PR or Issue may be a great consideration for a future idea.This PR or Issue may be a great consideration for a future idea.