1

I'm running some integration tests on my Ember app with Konacha.

Because of the nature of the tests, the Ember run loop is not disabled.

The tests work, but it seems that because I have not disabled the run loop (as outlined in the ember testing guide), I get this error in my console when the tests run:

Assertion failed: The URL '/' did match any routes in your application

But the tests do succeed regardless of this "error."

I've been playing around trying to remove the error from the console so that testing can be easier to see changes in, but I can't find a direct link between my tests and the error. The error happens whenever the Ember App object is initialized.

dax
  • 10,779
  • 8
  • 51
  • 86
alt
  • 13,357
  • 19
  • 80
  • 120
  • Do you have a list of routes you are visiting for your tests? Or better said, are you bouncing around to different routes? It's hard to diagnose with no code. – Kingpin2k Oct 21 '13 at 22:11
  • @kingpin2k it happens as soon as the application initializes unless I enable Ember testing. – alt Oct 22 '13 at 16:25
  • When you say _Because of the nature of the tests, the Ember run loop is not disabled._ do you mean that `App.setupForTesting();` isn't called, and `Ember.testing` is false? – Marcio Junior Oct 25 '13 at 23:04
  • @MárcioRodriguesCorreaJúnior setupForTesting has been called, but in order to keep the loop, Ember.testing is false. – alt Oct 25 '13 at 23:13
  • Have you tried to keep Ember.testing flag true, to check if the test behaves different? – Marcio Junior Oct 25 '13 at 23:15
  • @MárcioRodriguesCorreaJúnior I have, it does not stop the error. – alt Oct 25 '13 at 23:20
  • Can you show how you are setting the test? what do you have in the `setup`, `teardown`, `beforeEach` ... hooks – Marcio Junior Oct 25 '13 at 23:31

1 Answers1

0

Do you have a match for all at the end of your router?

this.route("matchall", {
    path: '*:'
});

Might help if you posted some sample routes and tests too.

Michael Benin
  • 4,317
  • 2
  • 23
  • 15