-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ci: 🎡 Use docker-compose for CI #97
base: master
Are you sure you want to change the base?
Conversation
* Use docker-compose to run tests on TravisCI * Fix tests failed for the latest Chrome * Fix tslint errors
- TRAVIS=1 | ||
- TRAVIS_JOB_NUMBER=dummy | ||
- TRAVIS_BRANCH=dummy | ||
- TRAVIS_COMMIT=dummy | ||
- TRAVIS_TAG=dummy | ||
- TRAVIS_REPO_SLUG=dummy | ||
- TRAVIS_COMMIT_MESSAGE=dummy | ||
- TRAVIS_BUILD_ID=dummy |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tests always fail on local environments without these definitions.
Definitions like - TRAVIS
(without =xxxx
) allows inherit specified environment variables and make tests pass only on TravisCI, or you can have them it pass locally if you define those variables. Please let me know if you like that.
- /app/node_modules | ||
working_dir: /app | ||
environment: | ||
- SELENIUM_URL=http://selenium:4444/wd/hub |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
docker-compose
launches 4 containers: app
, selenium
, firefox
, chrome
.
app
runs tests.- Protractor on
app
connects toselenium
to launch web browsers and control them. firefox
andchrome
registers themselves toselenium
.selenium
connects tofirefox
orchromes
based on the capability specified by protractor.
@@ -447,7 +447,7 @@ protractorUtil.registerJasmineReporter = function(context) { | |||
prefix: '' | |||
}; | |||
global.browser.getProcessedConfig().then(function(config) { | |||
if(config.capabilities) { | |||
if (config.capabilities) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ESLint error: Expected space(s) after "if" keyword-spacing
expect(report.tests[4].description).toMatch('\\[[M|L]\\] should list todos'); | ||
expect(report.tests[4].fullName).toMatch('\\[[M|L]\\] angularjs homepage todo list should list todos'); | ||
expect(report.tests[5].description).toMatch('\\[[M|L]\\] should add a todo'); | ||
expect(report.tests[5].fullName).toMatch('\\[[M|L]\\] angularjs homepage todo list should add a todo'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ESLint error: Unnecessary escape character: \[ no-useless-escape
Unnecessary escape character: \] no-useless-escape
@@ -4,7 +4,6 @@ exports.config = { | |||
seleniumAddress: env.seleniumAddress, | |||
framework: 'jasmine2', | |||
specs: ['../protractor/angularjs-homepage-disabled-test.js'], | |||
useBlockingProxy: true, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Somehow this causes tests fail (protractor raises an error Error from wait for angular
).
This isn't specified in default.js
and useBlockingProxy
looks have nothing to do with the purpose of bug55
, and I simply remove that.
@@ -128,14 +128,14 @@ describe("Screenshoter unit", function() { | |||
|
|||
it("should merge user config", function() { | |||
screenshoter.config = { | |||
screenshotPath: 'REPORTS', | |||
screenshotPath: 'REPORTS2', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
REPORTS
causes an error Error: EEXIST: file already exists, mkdir '/app/REPORTS'
on Windows. It looks conflict with the existing reports
. I changed the directory name to avoid the problem though it rather looks like an issue of mkdirp
.
TravisCI is failing for:
And I believe the test will fail just link azachar/screenshoter-report-analyzer#6 even if fix the above error in this way: