Skip to content

Commit 450aa84

Browse files
authored
Merge pull request #3138 from strongloop/fix/language-in-tests
Use English when running Mocha tests
2 parents dfa1f60 + 78f8b91 commit 450aa84

File tree

4 files changed

+12
-1
lines changed

4 files changed

+12
-1
lines changed

Gruntfile.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,7 @@ module.exports = function(grunt) {
9090
src: 'test/*.js',
9191
options: {
9292
reporter: 'dot',
93+
require: require.resolve('./test/helpers/use-english.js'),
9394
},
9495
},
9596
'unit-xml': {

test/helpers/use-english.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
'use strict';
2+
3+
var env = process.env;
4+
5+
// delete any user-provided language settings
6+
delete env.LC_ALL;
7+
delete env.LC_MESSAGES;
8+
delete env.LANG;
9+
delete env.LANGUAGE;
10+
delete env.STRONGLOOP_GLOBALIZE_APP_LANGUAGE;

test/karma.conf.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ module.exports = function(config) {
2121
// list of files / patterns to load in the browser
2222
files: [
2323
'node_modules/es5-shim/es5-shim.js',
24-
'test/support.js',
2524
'test/loopback.test.js',
2625
'test/model.test.js',
2726
// [rfeng] Browserified common/models/application.js

test/mocha.opts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
--require ./test/helpers/use-english

0 commit comments

Comments
 (0)