Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
50b2b3f5
Commit
50b2b3f5
authored
Jun 14, 2017
by
Mike Greiling
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add DEBUG flag option to karma config
parent
d70be8f8
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
6 deletions
+20
-6
.gitlab-ci.yml
.gitlab-ci.yml
+3
-0
config/karma.config.js
config/karma.config.js
+17
-6
No files found.
.gitlab-ci.yml
View file @
50b2b3f5
...
...
@@ -448,13 +448,16 @@ karma:
<<
:
*except-docs
variables
:
BABEL_ENV
:
"
coverage"
DEBUG
:
"
true"
script
:
-
bundle exec rake karma
coverage
:
'
/^Statements
*:
(\d+\.\d+%)/'
artifacts
:
name
:
coverage-javascript
expire_in
:
31d
when
:
always
paths
:
-
chrome_debug.log
-
coverage-javascript/
coverage
:
...
...
config/karma.config.js
View file @
50b2b3f5
...
...
@@ -21,14 +21,16 @@ module.exports = function(config) {
var
karmaConfig
=
{
basePath
:
ROOT_PATH
,
browsers
:
[
'
ChromeHeadless
NoSandbox
'
],
browsers
:
[
'
ChromeHeadless
Custom
'
],
customLaunchers
:
{
ChromeHeadless
NoSandbox
:
{
ChromeHeadless
Custom
:
{
base
:
'
ChromeHeadless
'
,
// chrome cannot run in sandboxed mode inside a docker container unless it is run with
// escalated kernel privileges: docker run --cap-add=CAP_SYS_ADMIN
flags
:
[
'
--no-sandbox
'
],
displayName
:
'
Chrome
'
displayName
:
'
Chrome
'
,
flags
:
[
// chrome cannot run in sandboxed mode inside a docker container unless it is run with
// escalated kernel privileges (e.g. docker run --cap-add=CAP_SYS_ADMIN)
'
--no-sandbox
'
,
],
}
},
frameworks
:
[
'
jasmine
'
],
...
...
@@ -54,5 +56,14 @@ module.exports = function(config) {
};
}
if
(
process
.
env
.
DEBUG
)
{
karmaConfig
.
logLevel
=
config
.
LOG_DEBUG
;
process
.
env
.
CHROME_LOG_FILE
=
process
.
env
.
CHROME_LOG_FILE
||
'
chrome_debug.log
'
;
}
if
(
process
.
env
.
CHROME_LOG_FILE
)
{
karmaConfig
.
customLaunchers
.
ChromeHeadlessCustom
.
flags
.
push
(
'
--enable-logging
'
,
'
--v=1
'
);
}
config
.
set
(
karmaConfig
);
};
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment