aboutsummaryrefslogtreecommitdiffstats
path: root/test/ng/locationSpec.js
diff options
context:
space:
mode:
authorPete Bacon Darwin2013-04-23 11:12:16 +0100
committerPete Bacon Darwin2013-04-25 19:08:41 +0100
commit0fbf584643bc52a11b50f6b1b563cc1b55a268c1 (patch)
tree7e803ad2774f4413c7f41b71df54a821808544ca /test/ng/locationSpec.js
parent5a8ae94f9c4a204253f01464a60577ba7daab866 (diff)
downloadangular.js-0fbf584643bc52a11b50f6b1b563cc1b55a268c1.tar.bz2
test(location): should not rewrite Html5 deep urls
Diffstat (limited to 'test/ng/locationSpec.js')
-rw-r--r--test/ng/locationSpec.js9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/ng/locationSpec.js b/test/ng/locationSpec.js
index 80addb95..bb0659a5 100644
--- a/test/ng/locationSpec.js
+++ b/test/ng/locationSpec.js
@@ -177,6 +177,15 @@ describe('$location', function() {
expect(url.absUrl()).toBe('http://www.domain.com:9877/a');
});
+ it('should not rewrite when hashbang url is not given', function() {
+ initService(true, '!', true);
+ inject(
+ initBrowser('http://domain.com/base/a/b', '/base'),
+ function($rootScope, $location, $browser) {
+ expect($browser.url()).toBe('http://domain.com/base/a/b');
+ }
+ );
+ });
it('should prepend path with basePath', function() {
url = new LocationHtml5Url('http://server/base/');