From: Dobrica Pavlinusic Date: Sun, 20 Jan 2013 23:45:30 +0000 (+0100) Subject: e2e scenario X-Git-Tag: 0.6~6 X-Git-Url: http://git.rot13.org/?p=angular-drzb;a=commitdiff_plain;h=1f7e047fe2f958781dd8c20b8535689b2a6d4ce8 e2e scenario --- diff --git a/test/e2e/scenarios.js b/test/e2e/scenarios.js index 26e174a..1b63871 100644 --- a/test/e2e/scenarios.js +++ b/test/e2e/scenarios.js @@ -5,40 +5,40 @@ describe('my app', function() { beforeEach(function() { - browser().navigateTo('../../app/index.html'); + browser().navigateTo('/lang/en/drzb2013.html'); }); - it('should automatically redirect to /view1 when location hash/fragment is empty', function() { - expect(browser().location().url()).toBe("/view1"); + it('should automatically redirect to /registration/ when location hash/fragment is empty', function() { + expect(browser().location().url()).toBe("/registration/"); }); - describe('view1', function() { + describe('registration', function() { beforeEach(function() { - browser().navigateTo('#/view1'); + browser().navigateTo('#/registration'); }); - it('should render view1 when user navigates to /view1', function() { - expect(element('[ng-view] p:first').text()). - toMatch(/partial for view 1/); + it('should render registration when user navigates to /registration', function() { + expect(element('[ng-view]').text()). + toMatch(/Registration/); }); }); - describe('view2', function() { + describe('list', function() { beforeEach(function() { - browser().navigateTo('#/view2'); + browser().navigateTo('#/list'); }); - it('should render view2 when user navigates to /view2', function() { - expect(element('[ng-view] p:first').text()). - toMatch(/partial for view 2/); + it('should render list when user navigates to /list', function() { + expect(element('[ng-view] div:first').text()). + toMatch(/Loading/); }); });