-
Notifications
You must be signed in to change notification settings - Fork 47
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(*) add docs e2e testing support for travis
* gulp build and npm run test-e2e rely on WITH_DOCS env var * WITH_DOCS env var declared in .travis.yml That way, doesn't change user workflow, but I still can test properly the doc generation
- Loading branch information
Showing
4 changed files
with
44 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
'use strict'; | ||
|
||
/** | ||
* This test is only run when the --with-docs flag is active : `npm run test-e2e -- --with-docs` | ||
* or when WITH_DOCS env variable is declared at true | ||
* | ||
* It's only meant to be run against a built version (also built with the flag --with-docs or WITH_DOCS env variable declared) | ||
* | ||
* This is not a documented feature. This is more to ensure on travis that not only: | ||
* - the doc generates correctly without failing | ||
* - but it also generates a correct output | ||
*/ | ||
|
||
// before each 'it' of the following describe: | ||
describe('Docs home page /docs', () => { | ||
beforeEach(() => { | ||
//go to page (if not yet) | ||
goToUrl('/docs'); | ||
}); | ||
it('should have a title', () => { | ||
expect(browser.getTitle()).toEqual('vanilla-es6-jspm'); | ||
}); | ||
it('should have a title in the header', () => { | ||
expect(element(by.css('h1.blue-main-title')).getText()).toEqual('vanilla-es6-jspm'); | ||
}); | ||
}); |