-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
feat: Add thirdPartyErrorFilterIntegration
#12267
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
Conversation
Ah, another issue here is that |
size-limit report 📦
|
| 'drop-error-if-exclusively-contains-third-party-frames' | ||
| 'apply-tag-if-contains-third-party-frames' | ||
| 'apply-tag-if-exclusively-contains-third-party-frames'; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are much better names!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yup, I agree. Your comment was a wake-up call 😂
}), | ||
} as unknown as Client; | ||
|
||
describe('ThirdPartyErrorFilter', () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
l: these tests lend themselves well to parameterization
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
True, but it's a bit annoying since we are checking for defined-ness and that is not so easy to do in parameterized tests.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you mean expect(result).toBeDefined();
? I think using expect.anything()
should work for that.
Described here:
#11718 (comment)
I didn't want to use the word
integrity
since for me at least, it reminds me of Subresource Integrity hashes and this is nothing like that. It's more of anid
. For the metadata property I usedbundle_key
although it might be a better idea to use something that is less likely to clash with users existing metadata like__bundler_key
.My only minor concern is the behaviour strings which use what feels like a double negative logic... drop-if-not-matched. It made it quite hard to reason about what each one did and I got the logic wrong myself a couple of times!