|
4 | 4 | * TODO: ES5 for now until I make a webpack plugin for protractor |
5 | 5 | */ |
6 | 6 | describe('App', function() { |
7 | | - var subject; |
8 | | - var result; |
9 | 7 |
|
10 | 8 | beforeEach(function() { |
11 | 9 | browser.get('/'); |
12 | 10 | }); |
13 | 11 |
|
14 | | - afterEach(function() { |
15 | | - expect(subject).toEqual(result); |
16 | | - }); |
17 | 12 |
|
18 | 13 | it('should have a title', function() { |
19 | | - subject = browser.getTitle(); |
20 | | - result = 'Angular2 Webpack Starter by @gdi2990 from @AngularClass'; |
| 14 | + var subject = browser.getTitle(); |
| 15 | + var result = 'Angular2 Webpack Starter by @gdi2990 from @AngularClass'; |
| 16 | + expect(subject).toEqual(result); |
21 | 17 | }); |
22 | 18 |
|
23 | 19 | it('should have <header>', function() { |
24 | | - subject = element(by.deepCss('app /deep/ header')).isPresent(); |
25 | | - result = true; |
| 20 | + var subject = element(by.deepCss('app /deep/ header')).isPresent(); |
| 21 | + var result = true; |
| 22 | + expect(subject).toEqual(result); |
26 | 23 | }); |
27 | 24 |
|
28 | 25 | it('should have <main>', function() { |
29 | | - subject = element(by.deepCss('app /deep/ main')).isPresent(); |
30 | | - result = true; |
| 26 | + var subject = element(by.deepCss('app /deep/ main')).isPresent(); |
| 27 | + var result = true; |
| 28 | + expect(subject).toEqual(result); |
31 | 29 | }); |
32 | 30 |
|
33 | 31 | it('should have <footer>', function() { |
34 | | - subject = element(by.deepCss('app /deep/ footer')).getText(); |
35 | | - result = 'WebPack Angular 2 Starter by @AngularClass'; |
| 32 | + var subject = element(by.deepCss('app /deep/ footer')).getText(); |
| 33 | + var result = 'WebPack Angular 2 Starter by @AngularClass'; |
| 34 | + expect(subject).toEqual(result); |
36 | 35 | }); |
37 | 36 |
|
38 | 37 | }); |
0 commit comments