Skip to content

Commit

Permalink
(GH1986) basic regression test of checkbox as POC.
Browse files Browse the repository at this point in the history
  • Loading branch information
Christopher McCulloh committed Jun 6, 2017
1 parent 8920788 commit 7df8b00
Show file tree
Hide file tree
Showing 93 changed files with 14,930 additions and 34 deletions.
4 changes: 3 additions & 1 deletion Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ module.exports = function gruntFile (grunt) {

// variables used in shared variables below
var connectTestServerOptionsPort = 9000;
var connectRegressionTestServerOptionsPort = 8013;

// load and initialize configuration tasks, including package.json's devDependencies
require('load-grunt-config')(grunt, {
Expand Down Expand Up @@ -69,7 +70,8 @@ module.exports = function gruntFile (grunt) {
// test dist with multiple jQuery versions
return 'http://localhost:' + connectTestServerOptionsPort + '/test/?testdist=true';
}),
connectTestServerOptionsPort: connectTestServerOptionsPort
connectTestServerOptionsPort: connectTestServerOptionsPort,
connectRegressionTestServerOptionsPort: connectRegressionTestServerOptionsPort
}
});

Expand Down
3 changes: 2 additions & 1 deletion dist/css/fuelux.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion dist/css/fuelux.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file modified dist/fuelux.zip
Binary file not shown.
3 changes: 2 additions & 1 deletion dist/js/fuelux.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/*!
* Fuel UX v3.16.0
* Fuel UX EDGE - Built 2017/06/05, 2:24:54 PM
* Previous release: v3.16.0
* Copyright 2012-2017 ExactTarget
* Licensed under the BSD-3-Clause license (https://github.com/ExactTarget/fuelux/blob/master/LICENSE)
*/
Expand Down
3 changes: 2 additions & 1 deletion dist/js/fuelux.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 15 additions & 3 deletions grunt/config/connect.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,19 @@ module.exports = function (grunt) {
port: '<%= connectTestServerOptionsPort %>',
useAvailablePort: true
}
},
regressionTestServer: {
options: {
base: {
path: '.',
options: {
index: ['index.html', 'tests.html']
}
},
hostname: '*',
port: '<%= connectRegressionTestServerOptionsPort %>',
useAvailablePort: true
}
}
}

};
};
};
19 changes: 15 additions & 4 deletions grunt/config/watch.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ module.exports = {
]
},
less: {
files: ['fonts/**',
files: ['fonts/**',
'less/**'],
options: {
livereload: true
Expand All @@ -65,20 +65,31 @@ module.exports = {
tasks: ['distcssdev']
},
dist: {
files: ['fonts/**',
files: ['fonts/**',
'grunt/**',
'js/**',
'js/**',
'less/**'],
options: {
livereload: true
},
tasks: ['dist']
},
reference: {
files: [
'reference/dist/css/**',
'reference/dist/fonts/**',
'reference/dist/js/**',
'reference/dist/templates/**'],
options: {
livereload: true
},
tasks: ['dist']
},
lite: {
files: [],
options: {
livereload: true
},
tasks: []
}
};
};
35 changes: 17 additions & 18 deletions grunt/tasks/serve.js
Original file line number Diff line number Diff line change
@@ -1,22 +1,18 @@
module.exports = function(grunt) {

/* -------------
SERVE
------------- */
// default serve task that runs tests and builds and tests dist by default.
grunt.registerTask('serve', 'Test, build, serve files. (~20s)', function () {
module.exports = function serveTasks (grunt) {
// runs tests and builds and tests dist by default.
grunt.registerTask('serve', 'Test, build, serve files. (~20s)', function serve () {
var tasks = ['test', 'servedist'];
grunt.task.run(tasks);
});

// serve task that runs tests and builds and tests dist by default (~20s).
grunt.registerTask('serveslow', 'Serve files. Run all tests. Does not build. (~20s)', function () {
grunt.registerTask('serveslow', 'Serve files. Run all tests. Does not build. (~20s)', function serveslow () {
var tasks = ['connect:server', 'test', 'watch:source'];
grunt.task.run(tasks);
});

//Fastest serve command for freely slinging code (no tests will run by default).
grunt.registerTask('servefast', 'Serve the files (no watch), --test to run minimal tests. (~0s)', function () {
// Fastest serve command for freely slinging code (no tests will run by default).
grunt.registerTask('servefast', 'Serve the files (no watch), --test to run minimal tests. (~0s)', function servefast () {
grunt.task.run(['connect:server']);

if (grunt.option('test')) {
Expand All @@ -27,7 +23,7 @@ module.exports = function(grunt) {
});

// Fastest serve command when you're working on LESS
grunt.registerTask('serveless', 'Compile LESS and serve the files. pass --tests to run test. (~3s)', function () {
grunt.registerTask('serveless', 'Compile LESS and serve the files. pass --tests to run test. (~3s)', function serveless () {
grunt.task.run(['distcss']);

if (grunt.option('test')) {
Expand All @@ -46,27 +42,30 @@ module.exports = function(grunt) {
});

// Complies the less files into the -dev versions, does not overwrite the main css files.
grunt.registerTask('servedev', 'Serve the files with no "dist" build or tests. Optional --no-less to also disable compiling less into css.', function() {
if (! grunt.option('no-less') ) {
grunt.registerTask('servedev', 'Serve the files with no "dist" build or tests. Optional --no-less to also disable compiling less into css.', function servedev () {
if ( !grunt.option('no-less') ) {
grunt.task.run(['distcssdev']);
}
grunt.task.run(['connect:server', 'watch:cssdev']);
});

// same as `grunt serve` but tests default to being off
grunt.registerTask('servedist', 'Compile and serve everything, pass --test to run tests. (~7s)', function () {
grunt.registerTask('servedist', 'Compile and serve everything, pass --test to run tests. (~7s)', function servedist () {
grunt.task.run(['dist']);

//start up the servers here so we can run tests if appropriate
// start up the servers here so we can run tests if appropriate
grunt.task.run(['connect:server']);
grunt.task.run(['connect:testServer']);

if (grunt.option('test')) {
grunt.task.run(['browserify:commonjs','qunit:dist', 'watch:full']);
grunt.task.run(['browserify:commonjs', 'qunit:dist', 'watch:full']);
} else {
grunt.task.run(['watch:dist']);
}
});


};
// http://localhost:8013/reference/
grunt.registerTask('serveregressiontests', 'Serve and watch regression test files', function serveregressiontests () {
grunt.task.run(['connect:regressionTestServer:keepalive']);
});
};
Loading

0 comments on commit 7df8b00

Please sign in to comment.