code: function (generatorFunc) {
              return function () {
                  var generator = generatorFunc.apply(this, arguments);
                  function doAction(action, arg) {
                      var result;    // in case error on first
                      // in case error on first
                      try {
                          result = generator[action](arg);
                      } catch (e) {
                          return new Reject(e);
                      }
                      if (result.done) {
                          return result.value;
                      }
                      return when(result.value, next, throwEx);
                  }
                  function next(v) {
                      return doAction('next', v);
                  }
                  function throwEx(e) {
                      return doAction('throw', e);
                  }
                  return next();
              };
          }
docs: provide es6 generator
  @param generatorFunc es6 generator function which has yielded promise