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

fix: log globals warning only once #1252

Merged
merged 1 commit into from
Nov 17, 2023
Merged

Conversation

MatanBobi
Copy link
Member

What: Resolves #1249

Why: To prevent the warning from being logged in every test suite.

How:

Checklist:

  • Documentation added to the
    docs site
  • Tests
  • TypeScript definitions updated
  • Ready to be merged

Copy link

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 6cf623e:

Sandbox Source
React Configuration
react-testing-library-examples Configuration

Copy link

codecov bot commented Nov 16, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (d80319f) 100.00% compared to head (6cf623e) 100.00%.

Additional details and impacted files
@@            Coverage Diff            @@
##              main     #1252   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            4         4           
  Lines          192       192           
  Branches        40        40           
=========================================
  Hits           192       192           
Flag Coverage Δ
canary 100.00% <ø> (ø)
experimental 100.00% <ø> (ø)
latest 100.00% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@timdeschryver timdeschryver left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@timdeschryver timdeschryver merged commit fd52a59 into main Nov 17, 2023
13 checks passed
@timdeschryver timdeschryver deleted the fix/log-warning-once branch November 17, 2023 14:46
@AviVahl
Copy link

AviVahl commented Nov 17, 2023

@MatanBobi
this caused a ReferenceError: process is not defined in our browser tests.
please note that typeof process === 'undefined' also goes into that if block.

@MatanBobi
Copy link
Member Author

@AviVahl - Sorry about that, totally missed it.
I'll issue a fix soon :)

@MatanBobi
Copy link
Member Author

This change was reverted :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Provide a better experience with lifecycle hooks
3 participants