Skip to content
Permalink
Browse files

Adding job name for pull request jobs coming from mergeatron

  • Loading branch information...
gnarf committed Nov 24, 2012
1 parent 67df705 commit 5c62ac80f00bbd86555cf3d45714789f831130e3
Showing with 12 additions and 2 deletions.
  1. +12 −2 grunt.js
@@ -126,11 +126,21 @@ module.exports = function( grunt ) {
grunt.loadNpmTasks( "grunt-update-submodules" );

grunt.registerTask( "testswarm", function( commit, configFile ) {
var testswarm = require( "testswarm" ),
var jobName,
testswarm = require( "testswarm" ),
testUrls = [],
pull = /PR-(\d+)/.exec( commit ),
config = grunt.file.readJSON( configFile ).jquery,
tests = "ajax attributes callbacks core css data deferred dimensions effects event manipulation offset queue serialize support traversing Sizzle".split(" ");

if ( pull ) {
jobName = "jQuery Pull Request <a href='https://github.com/jquery/jquery/pull/" +
pull[ 2 ] + "'>#" + pull[ 2 ] + "</a>";
} else {
jobName = "jQuery commit #<a href='https://github.com/jquery/jquery/commit/" +
commit + "'>" + commit.substr( 0, 10 ) + "</a>";
}

tests.forEach(function( test ) {
testUrls.push( config.testUrl + commit + "/test/index.html?module=" + test );
});
@@ -143,7 +153,7 @@ module.exports = function( grunt ) {
}, {
authUsername: config.authUsername,
authToken: config.authToken,
jobName: "jQuery commit #<a href='https://github.com/jquery/jquery/commit/" + commit + "'>" + commit.substr( 0, 10 ) + "</a>",
jobName: jobName,
runMax: config.runMax,
"runNames[]": tests,
"runUrls[]": testUrls,

0 comments on commit 5c62ac8

Please sign in to comment.
You can’t perform that action at this time.