You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
it('shouldn\'t treat the parameters in nested functions as dependencies',function(){varinjectedFuncWithNested=app.inject(function(app,login,Auth){functionnested(d,e,f){}varargs=Array.prototype.slice.call(arguments,0);returnargs.length;});expect(injectedFuncWithNested()).to.equal(3);});
I'm confused by app and login. They were never registered with the module, so how can they be used in the function during injection? If they should be ignored, then why would expect(injectedFunWithNested())).to.equal(3)?
The text was updated successfully, but these errors were encountered:
@linanqiu really good question. Actually, another student had the very same one. Please see issue 32 on js-course and let me know if that discussion clears things up for you.
I'm failing this test case
I'm confused by
app
andlogin
. They were never registered with the module, so how can they be used in the function during injection? If they should be ignored, then why wouldexpect(injectedFunWithNested())).to.equal(3)
?The text was updated successfully, but these errors were encountered: