Commit Graph

50 Commits

Author SHA1 Message Date
Brad Dunbar
33cdab412e Drop doubled test prefixes. 2012-09-05 08:52:27 -04:00
Brad Dunbar
f3be02e1e0 Add test for transition to hashChange. 2012-09-04 17:05:34 -04:00
Jerome Lecomte
1efeae70de fix #1619: fix navigation when root is empty
broken by commit d015ef1118
2012-09-04 14:31:30 -04:00
Brad Dunbar
d015ef1118 pushState/replaceState takes a relative url. 2012-09-04 09:53:46 -04:00
Brad Dunbar
65ed49bbaa Clean up.
* Remove accidental globals.
* Add missing semicolon.
* Clean up test.
2012-08-31 08:51:09 -04:00
Brad Dunbar
9a81468be7 Tweak root normalization. 2012-07-27 10:38:52 -04:00
Jamie Rolfs
596b12b56b Added test case for trailing slashs changes to atRoot in Backbone.history.start() 2012-07-26 12:12:41 -06:00
Jamie Rolfs
3d6b20ca7a Normalizing root url on Backbone.History.start, consistently matching root url for atRoot in History.start regardless of trailing slash 2012-07-26 11:44:07 -06:00
Jamie Rolfs
86cffe9bc2 Fixed Backbone.History.navigate and Backbone.History.start so any url changes include a slash between the root and route fragment when using pushState 2012-07-26 09:54:54 -06:00
Jeremy Ashkenas
9ee453f451 updating tests 2012-06-18 10:21:25 -04:00
Jeremy Ashkenas
2eeaa4a716 merged 2012-06-18 09:50:12 -04:00
Brad Dunbar
be5d4fd769 Fix #1366 - Root should not be prepended to history.fragment. 2012-06-16 12:45:08 -04:00
Brad Dunbar
27e9e4743c Fix #1387 - getFragment trims trailing slash before removing root.
* The root should not be stripped when dealing with hashes.
* The trailing slash can be removed since the fragment is
  stripped anyway.  This could probably be done only once
  in `start`, but is saved for a later patch.
* The mock pathname needs to prepend a slash in IE since
  anchor.pathname does not contain it.
2012-06-15 00:05:03 -04:00
Brad Dunbar
e4caafc68b Add router tests for #1185, #1206. 2012-06-12 22:28:29 -04:00
Brad Dunbar
2e2e9f7e96 Use mock location to test Backbone.history. 2012-06-12 11:57:50 -04:00
Brad Dunbar
85bd0b5132 Revert "Revert "Revert "Fix #1366 - Do not prepend root to history.fragment."""
This reverts commit ba980801ce.
2012-06-04 13:00:43 -04:00
Brad Dunbar
2939a2a412 Revert "Skip pushState tests with 'file:' protocol."
This reverts commit 76eeafcc3a.
2012-06-04 13:00:39 -04:00
Brad Dunbar
76eeafcc3a Skip pushState tests with 'file:' protocol. 2012-06-04 12:49:29 -04:00
Brad Dunbar
ba980801ce Revert "Revert "Fix #1366 - Do not prepend root to history.fragment.""
This reverts commit ceb68d7314.
2012-06-04 12:49:17 -04:00
Jeremy Ashkenas
ceb68d7314 Revert "Fix #1366 - Do not prepend root to history.fragment."
This reverts commit 2b0ad77f3b.
2012-06-04 10:52:22 -04:00
Jeremy Ashkenas
97379d6694 Merge pull request #1372 from braddunbar/fragment
Fix #1366 - Do not prepend root to history.fragment.
2012-06-04 07:48:21 -07:00
Brad Dunbar
7828d6d22d Prefer on/off over bind/unbind. 2012-06-03 15:06:44 -04:00
Sam Breed
f4ebee0406 adding the expected argument to all tests 2012-06-02 18:07:11 -06:00
Brad Dunbar
2b0ad77f3b Fix #1366 - Do not prepend root to history.fragment. 2012-06-02 10:51:11 -04:00
Brad Dunbar
70005fdd04 Update QUnit.
* Use `deepEqual` in place of `same`.
* Expect 0 tests where appropriate.
* Update view test to use #qunit-fixture.
* Remove `QUnit.config.reorder = false;`.
2012-05-02 20:54:27 -04:00
Jeremy Ashkenas
a2ed079af8 removing reg exp test. 2012-04-02 17:35:26 -04:00
Samuel Vogel
59b39c43a3 Add router test for urls with encoded characters 2012-03-29 17:17:29 +02:00
Aidan Feldman
f49969014c clean up tests to use fresh object instances for each run, and don't set
globals within test files
2012-03-12 04:27:22 -04:00
Jeremy Ashkenas
5ef4921c54 merging async test. 2012-02-27 14:37:50 -05:00
Jeremy Ashkenas
f930b5f042 adding additional router test 2012-02-27 14:37:13 -05:00
Jeremy Ashkenas
07604deac0 merging in hash fixer for FF 2012-02-27 14:30:23 -05:00
Jeremy Ashkenas
e5db1c93d0 Merge pull request #1011 from wookiehangover/issue996
adding test coverage for route precedence as per issue #996
2012-02-15 09:04:30 -08:00
Sam Breed
8d8a3599a9 adding test coverage for route precedence as per issue #996 2012-02-14 23:18:46 -07:00
Brad Dunbar
232c888038 fixes #1003 - History is started before navigate 2012-02-15 00:39:38 -05:00
Jake Harding
17459a316b Adding test for #967. 2012-02-07 14:17:53 -08:00
Brad Dunbar
3ef9c3a5fc Add tests for #908, #933. 2012-02-03 10:17:45 -05:00
Jeremy Ashkenas
96a7274cf7 Fixes #538 -- adds Backbone.history.stop() for unit testers. 2012-01-23 10:31:53 -05:00
Brad Dunbar
397d11e340 equals is deprecated; use equal instead
http://docs.jquery.com/QUnit/equal#actualexpectedmessage
2012-01-17 23:52:12 -05:00
Brad Dunbar
57ef21839b use implicit callback if none provided 2012-01-17 12:12:20 -05:00
Jeremy Ashkenas
5b43cd9dd1 Fixes #419 -- add a global 'route' event, on Bacckbone.history. 2012-01-13 13:47:55 -05:00
Jeremy Ashkenas
d5ff5e32f6 Fixes #786 (and others) -- leading slashes should never be defined as routes, or passed to navigate ... so strip 'em out proactively. 2012-01-12 18:10:41 -05:00
Jeremy Ashkenas
2312b9072c adding a test to ensure that routes aren't triggered multiple times. #849 2012-01-11 12:11:10 -05:00
Jeremy Ashkenas
1332246b8f merging in #750 -- support for replaceSTate 2011-11-23 14:59:14 -05:00
Aidan Feldman and Tim Harper
df7c279dc2 Navigate learns to change the route without adding a history entry
Also, instead of accepting a single boolean for trigger, the navigate
method now accepts an options object, with the following options:

- replace
- trigger

If you pass true instead of an options object, it's interpreted as
{trigger: true}

* pushState support - Aidan Feldman
* hashtag support and IE7 support - Tim Harper
* Tests were a joint effort.
2011-11-17 15:42:29 -07:00
Derick Bailey
6799c8e8be added a test and code to allow a router to define a route with no callback method for the route name 2011-10-06 19:09:53 -05:00
Jeremy Ashkenas
da6d0b90ca resolving merge conflict, removing old test. 2011-07-05 09:42:15 -04:00
Jeremy Ashkenas
d2082a54cf issue #451 + test. 2011-07-01 18:54:49 -04:00
Jeremy Ashkenas
ba1d9a1efd removing complex router text (unfixable) 2011-06-29 21:20:33 -04:00
Francis Gulotta
621c9edfc6 Test complex query strings. Fails in some browsers. 2011-06-17 15:37:12 -04:00
Jeremy Ashkenas
cf3215139a initial draft of a 0.5.0 branch 2011-05-26 10:54:28 -04:00