All Jasmine file manipulation/development moved from Thor to Grunt. Thor has been removed completely. Run grunt --help to see available tasks.

Canonical Jasmine version now lives in `package.json` (Node formatted) and is copied into Jasmine source (JavaScript and Ruby)

Jasmine distribution now has MIT license and Pivotal Labs copyright at the top of each distributed file.
This commit is contained in:
Davis W. Frank
2013-03-24 09:41:42 -07:00
parent 6b2d8da55f
commit edc2bfae93
35 changed files with 367 additions and 549 deletions

View File

@@ -1,14 +1,14 @@
var grunt = require("grunt");
var _ = require("underscore");
function standaloneTmpDir(path) { return "dist/tmp/" + path; }
module.exports = {
compileSpecRunner: function() {
var runnerTemplate = _.template(grunt.file.read("lib/templates/SpecRunner.html.jst")),
runner = runnerTemplate({ jasmineVersion: global.jasmineVersion });
var runnerHtml = grunt.template.process(
grunt.file.read("grunt/templates/SpecRunner.html.jst"),
{ data: { jasmineVersion: global.jasmineVersion }});
grunt.file.write(standaloneTmpDir("SpecRunner.html"), runner);
grunt.file.write(standaloneTmpDir("SpecRunner.html"), runnerHtml);
},
cleanSpecRunner: function() {

7
grunt/tasks/spec.js Normal file
View File

@@ -0,0 +1,7 @@
var shell = require('shelljs');
module.exports = {
execSpecsInNode: function() {
shell.exec("node spec/node_suite.js --color=true")
}
};

14
grunt/tasks/version.js Normal file
View File

@@ -0,0 +1,14 @@
var grunt = require("grunt");
function gemLib(path) { return './lib/jasmine-core/' + path; }
function nodeToRuby(version) { return version.replace('-', '.'); }
module.exports = {
copyToGem: function() {
var versionRb = grunt.template.process(
grunt.file.read("grunt/templates/version.rb.jst"),
{ data: { jasmineVersion: nodeToRuby(global.jasmineVersion) }});
grunt.file.write(gemLib("version.rb"), versionRb);
}
};