{"action":"created","issue":{"url":"https://api.github.com/repos/thoughtbot/suspenders/issues/646","labels_url":"https://api.github.com/repos/thoughtbot/suspenders/issues/646/labels{/name}","comments_url":"https://api.github.com/repos/thoughtbot/suspenders/issues/646/comments","events_url":"https://api.github.com/repos/thoughtbot/suspenders/issues/646/events","html_url":"https://github.com/thoughtbot/suspenders/pull/646","id":114332349,"number":646,"title":"Improve testability","user":{"login":"zamith","id":166304,"avatar_url":"https://avatars.githubusercontent.com/u/166304?v=3","gravatar_id":"","url":"https://api.github.com/users/zamith","html_url":"https://github.com/zamith","followers_url":"https://api.github.com/users/zamith/followers","following_url":"https://api.github.com/users/zamith/following{/other_user}","gists_url":"https://api.github.com/users/zamith/gists{/gist_id}","starred_url":"https://api.github.com/users/zamith/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zamith/subscriptions","organizations_url":"https://api.github.com/users/zamith/orgs","repos_url":"https://api.github.com/users/zamith/repos","events_url":"https://api.github.com/users/zamith/events{/privacy}","received_events_url":"https://api.github.com/users/zamith/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":11,"created_at":"2015-10-30T18:52:38Z","updated_at":"2015-11-09T15:24:53Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/thoughtbot/suspenders/pulls/646","html_url":"https://github.com/thoughtbot/suspenders/pull/646","diff_url":"https://github.com/thoughtbot/suspenders/pull/646.diff","patch_url":"https://github.com/thoughtbot/suspenders/pull/646.patch"},"body":"Improve testability for Heroku actions\r\n\r\nWhy:\r\n\r\n* It was very coupled and difficult to test in isolation, there was pretty much one single integration test.\r\n\r\nThis change addresses the need by:\r\n\r\n* Making it easier to test and reason about Heroku functionality we want to use, by allows for smaller, faster and more focused tests.\r\n* Using mocks instead of depending on side effects because it was tricky to build a fake of the an AppBuilder, that has a lot of functionality and it is already being tested in our integration tests.\r\n* Using a mockist approach, that ensures the correct methods are called with the right arguments (this last part is wip)\r\n\r\nInterested in opinions before I go much further with this. /cc @tute "},"comment":{"url":"https://api.github.com/repos/thoughtbot/suspenders/issues/comments/155094900","html_url":"https://github.com/thoughtbot/suspenders/pull/646#issuecomment-155094900","issue_url":"https://api.github.com/repos/thoughtbot/suspenders/issues/646","id":155094900,"user":{"login":"jferris","id":7591,"avatar_url":"https://avatars.githubusercontent.com/u/7591?v=3","gravatar_id":"","url":"https://api.github.com/users/jferris","html_url":"https://github.com/jferris","followers_url":"https://api.github.com/users/jferris/followers","following_url":"https://api.github.com/users/jferris/following{/other_user}","gists_url":"https://api.github.com/users/jferris/gists{/gist_id}","starred_url":"https://api.github.com/users/jferris/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jferris/subscriptions","organizations_url":"https://api.github.com/users/jferris/orgs","repos_url":"https://api.github.com/users/jferris/repos","events_url":"https://api.github.com/users/jferris/events{/privacy}","received_events_url":"https://api.github.com/users/jferris/received_events","type":"User","site_admin":false},"created_at":"2015-11-09T15:24:53Z","updated_at":"2015-11-09T15:24:53Z","body":"I don't know how hard it is, but I'd be interested in seeing the adapters restructured as other generators. We call some generators (like `rspec:install`), and I think it would be awesome if Suspenders could be broken down into largely calling a number of generators that you could opt in or out of.\r\n\r\nThat would also have the interesting effect of making it easier to pull in some Suspenders configurations after the fact, so you could opt out of mailer configs and then apply them later. This is something we've had a lot of requests for.\r\n\r\nIf that's particularly difficult, I could see the delegator-based adapter approach as a solid first step. Either way, I think it's great to see the app builder class getting broken up a bit; that thing has become massive and hard to navigate."}}