Merge pull request #72 from nabilbendafi/master

Fix e2e test
This commit is contained in:
ziajka 2018-02-27 11:36:51 +01:00 committed by GitHub
commit 142c996420
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 2 deletions

View File

@ -7,8 +7,8 @@ describe('gns3-web-ui App', () => {
page = new Gns3WebUiPage(); page = new Gns3WebUiPage();
}); });
it('should display welcome message', () => { it('should display title', () => {
page.navigateTo(); page.navigateTo();
expect(page.getParagraphText()).toEqual('Welcome to app!'); expect(page.getTitleText()).toEqual('GNS3 Web UI Demo');
}); });
}); });

View File

@ -5,6 +5,10 @@ export class Gns3WebUiPage {
return browser.get('/'); return browser.get('/');
} }
getTitleText() {
return browser.getTitle();
}
getParagraphText() { getParagraphText() {
return element(by.css('app-root h1')).getText(); return element(by.css('app-root h1')).getText();
} }