Skip to content
This repository was archived by the owner on Jul 29, 2024. It is now read-only.

Commit b6df2cf

Browse files
Nick Radfordjuliemr
Nick Radford
authored andcommitted
fix(configParser): load coffee and typescript for child processes
Without loading coffee in configParser.js, child processes which try and load a coffeescript config file do not have coffee registered with node's required, and child tests fail. Fixes an issue with using coffeescript config files.
1 parent 794e099 commit b6df2cf

File tree

2 files changed

+13
-16
lines changed

2 files changed

+13
-16
lines changed

lib/cli.js

-16
Original file line numberDiff line numberDiff line change
@@ -6,22 +6,6 @@
66
*/
77
'use strict';
88

9-
// Coffee is required here to enable config files written in coffee-script.
10-
// It's not directly used in this file, and not required.
11-
try {
12-
require('coffee-script').register();
13-
} catch (e) {
14-
// Intentionally blank - ignore if coffee-script is not available.
15-
}
16-
17-
// LiveScript is required here to enable config files written in LiveScript.
18-
// It's not directly used in this file, and not required.
19-
try {
20-
require('LiveScript');
21-
} catch (e) {
22-
// Intentionally blank - ignore if LiveScript is not available.
23-
}
24-
259
var util = require('util');
2610
var path = require('path');
2711
var child = require('child_process');

lib/configParser.js

+13
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,19 @@ var path = require('path'),
33
util = require('util'),
44
protractor = require('./protractor.js');
55

6+
// Coffee is required here to enable config files written in coffee-script.
7+
try {
8+
require('coffee-script').register();
9+
} catch (e) {
10+
// Intentionally blank - ignore if coffee-script is not available.
11+
}
12+
13+
// LiveScript is required here to enable config files written in LiveScript.
14+
try {
15+
require('LiveScript');
16+
} catch (e) {
17+
// Intentionally blank - ignore if LiveScript is not available.
18+
}
619

720
module.exports = ConfigParser = function() {
821
// Default configuration.

0 commit comments

Comments
 (0)