mirror of
https://github.com/moparisthebest/mail
synced 2024-11-25 18:32:20 -05:00
jshint on grunt test works again
This commit is contained in:
parent
1c234b7def
commit
6932088aa9
@ -1,4 +1,5 @@
|
|||||||
{
|
{
|
||||||
|
"indent": 4,
|
||||||
"strict": true,
|
"strict": true,
|
||||||
"globalstrict": true,
|
"globalstrict": true,
|
||||||
"node": true,
|
"node": true,
|
||||||
@ -29,7 +30,8 @@
|
|||||||
"deepEqual",
|
"deepEqual",
|
||||||
"start",
|
"start",
|
||||||
"chrome",
|
"chrome",
|
||||||
"define"
|
"define",
|
||||||
|
"self"
|
||||||
],
|
],
|
||||||
|
|
||||||
"globals": {
|
"globals": {
|
||||||
|
11
Gruntfile.js
11
Gruntfile.js
@ -24,9 +24,7 @@ module.exports = function(grunt) {
|
|||||||
keepalive: true,
|
keepalive: true,
|
||||||
middleware: function(connect, options) {
|
middleware: function(connect, options) {
|
||||||
// Return array of whatever middlewares you want
|
// Return array of whatever middlewares you want
|
||||||
return [
|
return [function(req, res, next) {
|
||||||
|
|
||||||
function(req, res, next) {
|
|
||||||
res.setHeader('Content-Security-Policy', "default-src 'self'; script-src 'self' 'unsafe-eval'; connect-src *; object-src 'none'; style-src 'self' 'unsafe-inline'");
|
res.setHeader('Content-Security-Policy', "default-src 'self'; script-src 'self' 'unsafe-eval'; connect-src *; object-src 'none'; style-src 'self' 'unsafe-inline'");
|
||||||
res.setHeader('X-Content-Security-Policy', "default-src *; script-src 'self' 'unsafe-eval'; options eval-script; object-src 'none'; style-src 'self' 'unsafe-inline'");
|
res.setHeader('X-Content-Security-Policy', "default-src *; script-src 'self' 'unsafe-eval'; options eval-script; object-src 'none'; style-src 'self' 'unsafe-inline'");
|
||||||
res.setHeader('X-WebKit-CSP', "default-src 'self'; script-src 'self' 'unsafe-eval'; connect-src *; object-src 'none'; style-src 'self' 'unsafe-inline'");
|
res.setHeader('X-WebKit-CSP', "default-src 'self'; script-src 'self' 'unsafe-eval'; connect-src *; object-src 'none'; style-src 'self' 'unsafe-inline'");
|
||||||
@ -42,7 +40,7 @@ module.exports = function(grunt) {
|
|||||||
},
|
},
|
||||||
|
|
||||||
jshint: {
|
jshint: {
|
||||||
all: ['Gruntfile.js', 'src/*.js', 'src/js/**/*.js', 'test/**/*.js'],
|
all: ['Gruntfile.js', 'src/*.js', 'src/js/**/*.js', 'test/unit/*.js', 'test/integration/*.js'],
|
||||||
options: {
|
options: {
|
||||||
jshintrc: '.jshintrc'
|
jshintrc: '.jshintrc'
|
||||||
}
|
}
|
||||||
@ -52,8 +50,7 @@ module.exports = function(grunt) {
|
|||||||
all: {
|
all: {
|
||||||
options: {
|
options: {
|
||||||
timeout: 20000,
|
timeout: 20000,
|
||||||
urls: [
|
urls: ['http://localhost:<%= connect.test.options.port %>/test/unit/index.html',
|
||||||
'http://localhost:<%= connect.test.options.port %>/test/unit/index.html',
|
|
||||||
'http://localhost:<%= connect.test.options.port %>/test/integration/index.html'
|
'http://localhost:<%= connect.test.options.port %>/test/integration/index.html'
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
@ -68,7 +65,7 @@ module.exports = function(grunt) {
|
|||||||
|
|
||||||
// Default task(s).
|
// Default task(s).
|
||||||
grunt.registerTask('dev', ['connect:dev']);
|
grunt.registerTask('dev', ['connect:dev']);
|
||||||
grunt.registerTask('test', ['connect:test', 'qunit']);
|
grunt.registerTask('test', ['jshint', 'connect:test', 'qunit']);
|
||||||
grunt.registerTask('prod', ['connect:prod']);
|
grunt.registerTask('prod', ['connect:prod']);
|
||||||
|
|
||||||
};
|
};
|
@ -1,4 +1,4 @@
|
|||||||
(function() {
|
define(['backbone', 'js/app-config'], function(Backbone, app) {
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
app.model.PrivateKey = Backbone.Model.extend({
|
app.model.PrivateKey = Backbone.Model.extend({
|
||||||
@ -20,4 +20,4 @@
|
|||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
}());
|
});
|
@ -1,4 +1,4 @@
|
|||||||
(function() {
|
define(['backbone', 'js/app-config'], function(Backbone, app) {
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
app.model.PublicKey = Backbone.Model.extend({
|
app.model.PublicKey = Backbone.Model.extend({
|
||||||
@ -19,4 +19,4 @@
|
|||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
}());
|
});
|
@ -20,9 +20,7 @@ require(['../../src/require-config'], function() {
|
|||||||
});
|
});
|
||||||
|
|
||||||
function startTests() {
|
function startTests() {
|
||||||
require([
|
require(['test/integration/cloudstorage-dao-test'], function() {
|
||||||
'test/integration/cloudstorage-dao-test'
|
|
||||||
], function() {
|
|
||||||
//Tests loaded, run tests
|
//Tests loaded, run tests
|
||||||
QUnit.start();
|
QUnit.start();
|
||||||
});
|
});
|
||||||
|
@ -19,8 +19,7 @@ require(['../../src/require-config'], function() {
|
|||||||
});
|
});
|
||||||
|
|
||||||
function startTests() {
|
function startTests() {
|
||||||
require([
|
require(['test/unit/forge-test',
|
||||||
'test/unit/forge-test',
|
|
||||||
'test/unit/aes-test',
|
'test/unit/aes-test',
|
||||||
'test/unit/rsa-test',
|
'test/unit/rsa-test',
|
||||||
'test/unit/lawnchair-dao-test',
|
'test/unit/lawnchair-dao-test',
|
||||||
|
Loading…
Reference in New Issue
Block a user