e2e scenario
authorDobrica Pavlinusic <dpavlin@rot13.org>
Sun, 20 Jan 2013 23:45:30 +0000 (00:45 +0100)
committerDobrica Pavlinusic <dpavlin@rot13.org>
Sun, 20 Jan 2013 23:45:30 +0000 (00:45 +0100)
test/e2e/scenarios.js

index 26e174a..1b63871 100644 (file)
@@ -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/);
     });
 
   });