{"action":"created","issue":{"url":"https://api.github.com/repos/facebook/react/issues/11098","repository_url":"https://api.github.com/repos/facebook/react","labels_url":"https://api.github.com/repos/facebook/react/issues/11098/labels{/name}","comments_url":"https://api.github.com/repos/facebook/react/issues/11098/comments","events_url":"https://api.github.com/repos/facebook/react/issues/11098/events","html_url":"https://github.com/facebook/react/issues/11098","id":262949027,"node_id":"MDU6SXNzdWUyNjI5NDkwMjc=","number":11098,"title":"Allow suppressing error boundary logs from intentionally thrown/caught errors","user":{"login":"gaearon","id":810438,"node_id":"MDQ6VXNlcjgxMDQzOA==","avatar_url":"https://avatars0.githubusercontent.com/u/810438?v=4","gravatar_id":"","url":"https://api.github.com/users/gaearon","html_url":"https://github.com/gaearon","followers_url":"https://api.github.com/users/gaearon/followers","following_url":"https://api.github.com/users/gaearon/following{/other_user}","gists_url":"https://api.github.com/users/gaearon/gists{/gist_id}","starred_url":"https://api.github.com/users/gaearon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gaearon/subscriptions","organizations_url":"https://api.github.com/users/gaearon/orgs","repos_url":"https://api.github.com/users/gaearon/repos","events_url":"https://api.github.com/users/gaearon/events{/privacy}","received_events_url":"https://api.github.com/users/gaearon/received_events","type":"User","site_admin":false},"labels":[{"id":127893911,"node_id":"MDU6TGFiZWwxMjc4OTM5MTE=","url":"https://api.github.com/repos/facebook/react/labels/Component:%20DOM","name":"Component: DOM","color":"fef2c0","default":false},{"id":588833528,"node_id":"MDU6TGFiZWw1ODg4MzM1Mjg=","url":"https://api.github.com/repos/facebook/react/labels/Difficulty:%20medium","name":"Difficulty: medium","color":"fbca04","default":false},{"id":40929153,"node_id":"MDU6TGFiZWw0MDkyOTE1Mw==","url":"https://api.github.com/repos/facebook/react/labels/Type:%20Enhancement","name":"Type: Enhancement","color":"84b6eb","default":false},{"id":725156255,"node_id":"MDU6TGFiZWw3MjUxNTYyNTU=","url":"https://api.github.com/repos/facebook/react/labels/good%20first%20issue%20(taken)","name":"good first issue (taken)","color":"b60205","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":17,"created_at":"2017-10-04T22:20:27Z","updated_at":"2018-07-24T01:09:34Z","closed_at":null,"author_association":"MEMBER","body":"-----\r\n\r\n**(This is a repost of https://github.com/facebook/jest/issues/4597 by @erikras.)**\r\n\r\n----\r\n\r\n**Do you want to request a *feature* or report a *bug*?**\r\n\r\nSomewhere in between?\r\n\r\n**What is the current behavior?**\r\n\r\nWhen I'm running tests on [my library](https://github.com/erikras/redux-form), there are some behaviors that I want to test _do_ throw an error. These currently result in:\r\n\r\n```\r\nConsider adding an error boundary to your tree to customize error handling behavior.\r\nYou can learn more about error boundaries at https://fb.me/react-error-boundaries.\r\n```\r\n\r\n...being output to the console. This error is great in an application, but not so great for a library test.\r\n\r\n**What is the expected behavior?**\r\n\r\nIt would be great if I could do something like:\r\n```jsx\r\nexpect(() => {\r\n  TestUtils.renderIntoDocument(<DoSomething naughty/>)\r\n})\r\n.toThrow(/Bad developer!/)\r\n.andCatch() // <---- prevents React 16 error boundary warning\r\n```\r\n\r\n**Please provide your exact Jest configuration and mention your Jest, node, yarn/npm version and operating system.**\r\n\r\n```\r\njest@21.2.1\r\nreact@16.0.0\r\nreact-dom@16.0.0\r\n```\r\n\r\n**See also**\r\n\r\n- https://github.com/facebook/react/issues/11083\r\n- https://github.com/facebook/react/issues/10474#issuecomment-334164834\r\n"},"comment":{"url":"https://api.github.com/repos/facebook/react/issues/comments/407247500","html_url":"https://github.com/facebook/react/issues/11098#issuecomment-407247500","issue_url":"https://api.github.com/repos/facebook/react/issues/11098","id":407247500,"node_id":"MDEyOklzc3VlQ29tbWVudDQwNzI0NzUwMA==","user":{"login":"craigkovatch","id":10970257,"node_id":"MDQ6VXNlcjEwOTcwMjU3","avatar_url":"https://avatars2.githubusercontent.com/u/10970257?v=4","gravatar_id":"","url":"https://api.github.com/users/craigkovatch","html_url":"https://github.com/craigkovatch","followers_url":"https://api.github.com/users/craigkovatch/followers","following_url":"https://api.github.com/users/craigkovatch/following{/other_user}","gists_url":"https://api.github.com/users/craigkovatch/gists{/gist_id}","starred_url":"https://api.github.com/users/craigkovatch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/craigkovatch/subscriptions","organizations_url":"https://api.github.com/users/craigkovatch/orgs","repos_url":"https://api.github.com/users/craigkovatch/repos","events_url":"https://api.github.com/users/craigkovatch/events{/privacy}","received_events_url":"https://api.github.com/users/craigkovatch/received_events","type":"User","site_admin":false},"created_at":"2018-07-24T01:09:34Z","updated_at":"2018-07-24T01:09:34Z","author_association":"NONE","body":"This is still causing tons of noise in our unit tests. Anyone working on this?"}}
{"actor":{"display_login":"craigkovatch"}}