Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stop polyfilling Promise in Jest tests #34659

Closed
wants to merge 3 commits into from

Commits on Sep 11, 2022

  1. Fix LogBoxSymbolication-test

    Differential Revision: D39418412
    
    fbshipit-source-id: e2b76fa91df28ce1418a487f45dbeb590a66d184
    robhogan authored and facebook-github-bot committed Sep 11, 2022
    Configuration menu
    Copy the full SHA
    4c4f967 View commit details
    Browse the repository at this point in the history
  2. Allow LogBoxLog-test to work with native promises

    Differential Revision: D39418413
    
    fbshipit-source-id: 7b4c96c62ada4ef7cd5231b305c926068026df38
    robhogan authored and facebook-github-bot committed Sep 11, 2022
    Configuration menu
    Copy the full SHA
    ffe0cd9 View commit details
    Browse the repository at this point in the history
  3. Stop polyfilling Promise in Jest tests

    Summary:
    We've used this Promise polyfill in Jest setup since at least 2015 ([`3ff3987`](facebook@3ff3987)), when native Promise implementations were either non-existent or new and unstable. We no longer need it.
    
    It causes issues with "modern" timers in Jest, as documented in:
     - facebook#29303
     - jestjs/jest#10221
    
    It can also obscure real issues due to its default silent handling of uncaught rejections, eg: D39418412.
    
    Changelog:
    [General][Changed] - Don't polyfill Promise in Jest setup
    
    Differential Revision: D39417597
    
    fbshipit-source-id: 1773032343f914a37789c7bc43760838f2d86d31
    robhogan authored and facebook-github-bot committed Sep 11, 2022
    Configuration menu
    Copy the full SHA
    6465677 View commit details
    Browse the repository at this point in the history