{"action":"opened","issue":{"url":"https://api.github.com/repos/kingpong/perl-Test-Spec/issues/35","repository_url":"https://api.github.com/repos/kingpong/perl-Test-Spec","labels_url":"https://api.github.com/repos/kingpong/perl-Test-Spec/issues/35/labels{/name}","comments_url":"https://api.github.com/repos/kingpong/perl-Test-Spec/issues/35/comments","events_url":"https://api.github.com/repos/kingpong/perl-Test-Spec/issues/35/events","html_url":"https://github.com/kingpong/perl-Test-Spec/issues/35","id":158297597,"number":35,"title":"Checks with name overrides context name","user":{"login":"happy-barney","id":971372,"avatar_url":"https://avatars.githubusercontent.com/u/971372?v=3","gravatar_id":"","url":"https://api.github.com/users/happy-barney","html_url":"https://github.com/happy-barney","followers_url":"https://api.github.com/users/happy-barney/followers","following_url":"https://api.github.com/users/happy-barney/following{/other_user}","gists_url":"https://api.github.com/users/happy-barney/gists{/gist_id}","starred_url":"https://api.github.com/users/happy-barney/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/happy-barney/subscriptions","organizations_url":"https://api.github.com/users/happy-barney/orgs","repos_url":"https://api.github.com/users/happy-barney/repos","events_url":"https://api.github.com/users/happy-barney/events{/privacy}","received_events_url":"https://api.github.com/users/happy-barney/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-06-03T06:07:07Z","updated_at":"2016-06-03T06:07:07Z","closed_at":null,"body":"Example:\r\n```perl\r\nuse Test::Exception;\r\nuse Test::Spec;\r\n\r\nsub as (&) { shift; }\r\n\r\ndescribe \"what\" => as {\r\n    context \"when\" => as {\r\n        my $obj;\r\n        it 'should pass' => as { pass };\r\n        it 'should pass with name' => as { pass \"with name\" };\r\n        it 'should die' => as { throws_ok { $obj->build ({}) } qr/^(?=.*\\bbuild\\b)/ };\r\n    };\r\n};\r\n\r\nruntests unless caller;\r\n```\r\n\r\nOutput:\r\n```\r\nok 1 - what when should pass\r\nok 2 - with name\r\nok 3 - threw Regexp ((?^:^(?=.*\\bbuild\\b)))\r\n1..3\r\n```\r\n\r\nExpected output:\r\n```\r\nok 1 - what when should pass\r\nok 2 - what when should pass with name\r\nok 3 - what when should die\r\n1..3\r\n```\r\n\r\nBetter output (mimics Test::More::subtest)\r\n```\r\n    # describe: what\r\n        # context: what when\r\n        ok 1 - what when should pass\r\n        ok 2 - what when should pass with name\r\n        ok 3 - what when should die\r\n        1..3\r\n    ok 1 - what when\r\n    1..1\r\nok 1 - what\r\n1..1\r\n```"}}
{"actor":{"display_login":"happy-barney"}}