{"action":"created","issue":{"url":"https://api.github.com/repos/spion/blue-tape/issues/6","labels_url":"https://api.github.com/repos/spion/blue-tape/issues/6/labels{/name}","comments_url":"https://api.github.com/repos/spion/blue-tape/issues/6/comments","events_url":"https://api.github.com/repos/spion/blue-tape/issues/6/events","html_url":"https://github.com/spion/blue-tape/issues/6","id":62484092,"number":6,"title":"Adding Generator Support?","user":{"login":"wavded","id":26638,"avatar_url":"https://avatars.githubusercontent.com/u/26638?v=3","gravatar_id":"","url":"https://api.github.com/users/wavded","html_url":"https://github.com/wavded","followers_url":"https://api.github.com/users/wavded/followers","following_url":"https://api.github.com/users/wavded/following{/other_user}","gists_url":"https://api.github.com/users/wavded/gists{/gist_id}","starred_url":"https://api.github.com/users/wavded/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wavded/subscriptions","organizations_url":"https://api.github.com/users/wavded/orgs","repos_url":"https://api.github.com/users/wavded/repos","events_url":"https://api.github.com/users/wavded/events{/privacy}","received_events_url":"https://api.github.com/users/wavded/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":21,"created_at":"2015-03-17T18:52:56Z","updated_at":"2015-03-18T15:57:05Z","closed_at":null,"body":"@spion just a thought to throw your way to get your thoughts.  If a user passes a generator function for a test, wrap it in a `Promise.coroutine` call (or something like that) in order to `yield` promises, etc.  Here is an implementation I'm using currently that wraps blue-tape.\r\n\r\n```js\r\nimport test from 'blue-tape'\r\nimport Promise from 'bluebird'\r\n\r\nexport default function genTest (...args) {\r\n  let testArgs = args.map( arg => {\r\n    if (arg && arg.constructor.name === 'GeneratorFunction') {\r\n      return Promise.coroutine(arg)\r\n    }\r\n\r\n    return arg\r\n  })\r\n  test.apply(null, testArgs)\r\n}\r\n```\r\n\r\nAllowing tests like so:\r\n\r\n```js\r\ntest('User#save', function* (t) {\r\n  let user = common.initUser()\r\n  user.password = 'foo'\r\n  yield user.save()\r\n  console.log(user.password)\r\n})\r\n```\r\n\r\nThoughts?"},"comment":{"url":"https://api.github.com/repos/spion/blue-tape/issues/comments/83033374","html_url":"https://github.com/spion/blue-tape/issues/6#issuecomment-83033374","issue_url":"https://api.github.com/repos/spion/blue-tape/issues/6","id":83033374,"user":{"login":"getify","id":150330,"avatar_url":"https://avatars.githubusercontent.com/u/150330?v=3","gravatar_id":"","url":"https://api.github.com/users/getify","html_url":"https://github.com/getify","followers_url":"https://api.github.com/users/getify/followers","following_url":"https://api.github.com/users/getify/following{/other_user}","gists_url":"https://api.github.com/users/getify/gists{/gist_id}","starred_url":"https://api.github.com/users/getify/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/getify/subscriptions","organizations_url":"https://api.github.com/users/getify/orgs","repos_url":"https://api.github.com/users/getify/repos","events_url":"https://api.github.com/users/getify/events{/privacy}","received_events_url":"https://api.github.com/users/getify/received_events","type":"User","site_admin":false},"created_at":"2015-03-18T15:57:05Z","updated_at":"2015-03-18T15:57:05Z","body":"oh, ok, my mistake. I shouldn't have been speaking without more fully understanding the code in the lib. I was only going off the impressions left by the initial OP. <shuts up> :)"}}