{"action":"created","issue":{"url":"https://api.github.com/repos/switchfly/ember-test-helpers/issues/38","labels_url":"https://api.github.com/repos/switchfly/ember-test-helpers/issues/38/labels{/name}","comments_url":"https://api.github.com/repos/switchfly/ember-test-helpers/issues/38/comments","events_url":"https://api.github.com/repos/switchfly/ember-test-helpers/issues/38/events","html_url":"https://github.com/switchfly/ember-test-helpers/pull/38","id":67022821,"number":38,"title":"Support component integration tests","user":{"login":"ef4","id":319282,"avatar_url":"https://avatars.githubusercontent.com/u/319282?v=3","gravatar_id":"","url":"https://api.github.com/users/ef4","html_url":"https://github.com/ef4","followers_url":"https://api.github.com/users/ef4/followers","following_url":"https://api.github.com/users/ef4/following{/other_user}","gists_url":"https://api.github.com/users/ef4/gists{/gist_id}","starred_url":"https://api.github.com/users/ef4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ef4/subscriptions","organizations_url":"https://api.github.com/users/ef4/orgs","repos_url":"https://api.github.com/users/ef4/repos","events_url":"https://api.github.com/users/ef4/events{/privacy}","received_events_url":"https://api.github.com/users/ef4/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":22,"created_at":"2015-04-08T00:56:34Z","updated_at":"2015-05-03T14:57:48Z","closed_at":"2015-05-03T14:57:17Z","pull_request":{"url":"https://api.github.com/repos/switchfly/ember-test-helpers/pulls/38","html_url":"https://github.com/switchfly/ember-test-helpers/pull/38","diff_url":"https://github.com/switchfly/ember-test-helpers/pull/38.diff","patch_url":"https://github.com/switchfly/ember-test-helpers/pull/38.patch"},"body":"This implements template-driven component integration tests. See previous discussion in #25.\r\n\r\n`TestModuleForComponent` now offers both a unit test mode (which is unchanged from the present behavior) and an integration test mode (which subsumes previous ModuleForIntegration).\r\n\r\n~~The default is integration test mode, because~~ I am 100% convinced that is the way most people should be testing most components most of the time. ~~We switch to unit test mode if you provide an explicit `needs` argument, or say `unit: true`, or say `integration:false`.~~\r\n\r\nIn integration mode, tests are template-driven, giving you full and intuitive access to all features of components, including passing them block templates, yielding block params, and action handling.\r\n\r\n~~People with existing component unit tests that already have a `needs` parameter (which I expect is most of them) will not be affected by this change. But people with component unit tests and no `needs` parameter will get failing tests, until they add `unit: true` to their module. This is a very low-cost upgrade pain, so I think it's worth it for achieving a simpler API that nudges people toward the right choice by default.~~\r\n\r\n*Edited to add: after feedback, I changed this to not be a breaking change. Unit test mode is still the default, but we will hit you with a deprecation warning unless you add an explicit `needs` or `unit:true`, which will protect you from a future change that makes integration mode the default.*\r\n\r\nI have tested this change with both ember-mocha and ember-qunit, and no changes are actually required in either of them to use this functionality. We will want to update their ember-cli blueprint generators however, so that they can generate both unit and integration tests for components, and so they place them under an appropriate path (like `tests/integration` instead of `tests/unit`)."},"comment":{"url":"https://api.github.com/repos/switchfly/ember-test-helpers/issues/comments/98490551","html_url":"https://github.com/switchfly/ember-test-helpers/pull/38#issuecomment-98490551","issue_url":"https://api.github.com/repos/switchfly/ember-test-helpers/issues/38","id":98490551,"user":{"login":"dgeb","id":29122,"avatar_url":"https://avatars.githubusercontent.com/u/29122?v=3","gravatar_id":"","url":"https://api.github.com/users/dgeb","html_url":"https://github.com/dgeb","followers_url":"https://api.github.com/users/dgeb/followers","following_url":"https://api.github.com/users/dgeb/following{/other_user}","gists_url":"https://api.github.com/users/dgeb/gists{/gist_id}","starred_url":"https://api.github.com/users/dgeb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dgeb/subscriptions","organizations_url":"https://api.github.com/users/dgeb/orgs","repos_url":"https://api.github.com/users/dgeb/repos","events_url":"https://api.github.com/users/dgeb/events{/privacy}","received_events_url":"https://api.github.com/users/dgeb/received_events","type":"User","site_admin":false},"created_at":"2015-05-03T14:57:48Z","updated_at":"2015-05-03T14:57:48Z","body":"Thanks for all your work (and patience) @ef4! :shipit: "}}