{"action":"created","issue":{"url":"https://api.github.com/repos/phpspec/phpspec/issues/973","repository_url":"https://api.github.com/repos/phpspec/phpspec","labels_url":"https://api.github.com/repos/phpspec/phpspec/issues/973/labels{/name}","comments_url":"https://api.github.com/repos/phpspec/phpspec/issues/973/comments","events_url":"https://api.github.com/repos/phpspec/phpspec/issues/973/events","html_url":"https://github.com/phpspec/phpspec/pull/973","id":166378359,"number":973,"title":"Improve the default specification template","user":{"login":"everzet","id":30813,"avatar_url":"https://avatars.githubusercontent.com/u/30813?v=3","gravatar_id":"","url":"https://api.github.com/users/everzet","html_url":"https://github.com/everzet","followers_url":"https://api.github.com/users/everzet/followers","following_url":"https://api.github.com/users/everzet/following{/other_user}","gists_url":"https://api.github.com/users/everzet/gists{/gist_id}","starred_url":"https://api.github.com/users/everzet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/everzet/subscriptions","organizations_url":"https://api.github.com/users/everzet/orgs","repos_url":"https://api.github.com/users/everzet/repos","events_url":"https://api.github.com/users/everzet/events{/privacy}","received_events_url":"https://api.github.com/users/everzet/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":9,"created_at":"2016-07-19T16:42:18Z","updated_at":"2016-07-21T11:07:30Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/phpspec/phpspec/pulls/973","html_url":"https://github.com/phpspec/phpspec/pull/973","diff_url":"https://github.com/phpspec/phpspec/pull/973.diff","patch_url":"https://github.com/phpspec/phpspec/pull/973.patch"},"body":"Original `it_is_initializable` was used to address one particular\r\nproblem in the PhpSpec 2.0 design - only one generator was being\r\nexecuted during a single `phpspec run`. So basically, if back then\r\nyou described a new spec and then immediately wrote an example for\r\nit, you were forced to run `phpspec run` twice - once to generate\r\nthe object and once to generate the method itself. To avoid this\r\nproblem I added `it_is_initializable` example into the\r\nspecification template. So that when you `describe` and then\r\nimmediately execute ` run`, PhpSpec generates an object for you.\r\nThat limited situations when you needed to rerun specs just\r\nbecause of code generation. That's it.\r\n\r\n@ciaranmcnulty solved the real problem in 2.1 by introducing\r\nautomated specification rerun on code generation. This made this\r\nfunctionality redundant.\r\n\r\nRedundancy is a good enough reason to change template on its own,\r\nbut I have a bigger reason - I see way too many specs with\r\n`it_is_initializable` still in them. This particular \"example\" is\r\nnot a real example and was never supposed to be used for anything\r\nbut the use case described above.\r\n\r\nThis change both removes meaningless example and provides a\r\nbetter starting point for PhpSpec newcomers by giving them a\r\nbetter example template to start."},"comment":{"url":"https://api.github.com/repos/phpspec/phpspec/issues/comments/234223613","html_url":"https://github.com/phpspec/phpspec/pull/973#issuecomment-234223613","issue_url":"https://api.github.com/repos/phpspec/phpspec/issues/973","id":234223613,"user":{"login":"everzet","id":30813,"avatar_url":"https://avatars.githubusercontent.com/u/30813?v=3","gravatar_id":"","url":"https://api.github.com/users/everzet","html_url":"https://github.com/everzet","followers_url":"https://api.github.com/users/everzet/followers","following_url":"https://api.github.com/users/everzet/following{/other_user}","gists_url":"https://api.github.com/users/everzet/gists{/gist_id}","starred_url":"https://api.github.com/users/everzet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/everzet/subscriptions","organizations_url":"https://api.github.com/users/everzet/orgs","repos_url":"https://api.github.com/users/everzet/repos","events_url":"https://api.github.com/users/everzet/events{/privacy}","received_events_url":"https://api.github.com/users/everzet/received_events","type":"User","site_admin":false},"created_at":"2016-07-21T11:07:30Z","updated_at":"2016-07-21T11:07:30Z","body":"```\r\nfunction it_()\r\n{\r\n}\r\n```"}}
{"actor":{"display_login":"everzet"}}