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

fbt-runtime-test: it should only expect "missing translation" console warnings #22

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

kayhadrin
Copy link
Collaborator

@kayhadrin kayhadrin commented Jan 4, 2025

This will help detect any other unexpected runtime warning that might be thrown by the fbt library.

… warnings

This will help detect any other unexpected runtime warning that might be thrown by the fbt library.
cpojer

This comment was marked as outdated.

Copy link
Collaborator

@cpojer cpojer left a comment

Choose a reason for hiding this comment

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

This change only actually verifies the assertion if the function is called at all. Instead, we should use expect(console.warn).toHaveBeenCalledWith(…) in the test where we expect console.warn to be called . This ensures that the function is actually called.

@kayhadrin kayhadrin self-assigned this Jan 9, 2025
@kayhadrin kayhadrin added the enhancement New feature or request label Jan 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants