Here's a working example of the issue: http://plnkr.co/edit/diIxwxc2D8BJo7cOzKmh?p=preview
On Friday, February 27, 2015 at 1:18:38 PM UTC-8, John Therrell wrote: > > Hi Everyone, > > I want to test a directive using a mock $window object so I can control > the $window.location.protocol property which the directive inspects. > However, my mock $window seems to also be used in my test code and my > $compile calls in the test code and I can't create an element to test the > directive. > > Does angular provide a way for me to inject my mock $window only into my > directive and allow me to use the real $window in other modules and test > code? > > I have a gist of my issue here: > https://gist.github.com/anonymous/61e7d79021391536f7f2 > > Thanks, > John > -- You received this message because you are subscribed to the Google Groups "AngularJS" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/angular. For more options, visit https://groups.google.com/d/optout.
