{"action":"closed","issue":{"url":"https://api.github.com/repos/facebook/react/issues/4725","labels_url":"https://api.github.com/repos/facebook/react/issues/4725/labels{/name}","comments_url":"https://api.github.com/repos/facebook/react/issues/4725/comments","events_url":"https://api.github.com/repos/facebook/react/issues/4725/events","html_url":"https://github.com/facebook/react/issues/4725","id":103545194,"number":4725,"title":"ReactElementValidator.loggedTypeFailures prevents test isolation","user":{"login":"ryanwilsonperkin","id":3004111,"avatar_url":"https://avatars.githubusercontent.com/u/3004111?v=3","gravatar_id":"","url":"https://api.github.com/users/ryanwilsonperkin","html_url":"https://github.com/ryanwilsonperkin","followers_url":"https://api.github.com/users/ryanwilsonperkin/followers","following_url":"https://api.github.com/users/ryanwilsonperkin/following{/other_user}","gists_url":"https://api.github.com/users/ryanwilsonperkin/gists{/gist_id}","starred_url":"https://api.github.com/users/ryanwilsonperkin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ryanwilsonperkin/subscriptions","organizations_url":"https://api.github.com/users/ryanwilsonperkin/orgs","repos_url":"https://api.github.com/users/ryanwilsonperkin/repos","events_url":"https://api.github.com/users/ryanwilsonperkin/events{/privacy}","received_events_url":"https://api.github.com/users/ryanwilsonperkin/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-08-27T16:18:44Z","updated_at":"2015-08-28T20:00:00Z","closed_at":"2015-08-28T20:00:00Z","body":"I'm running React v0.13.3 and testing with jasmine-core v2.3.4.\r\n\r\nWhen testing my component validation, I use jasmine's `spyOn` method to mock out `console.warn` and check that `TestUtils.renderIntoDocument` will trigger a warning with the correct message when validation fails. I use `expect(console.warn).toHaveBeenCalledWith(...)` to check that validation is working.\r\n\r\nI run the same unit test, in two separate test suites (`tests/fileA.js` and `tests/fileB.js`) that expects the warning to occur. Because React globally tracks which warnings have been triggered (to avoid spamming the console it seems) it doesn't send the warning the second time, and thus fails.\r\n\r\nI would expect that `TestUtils.renderIntoDocument` would setup isolation for each render so that warnings can be checked properly."}}