diff --git a/.gitignore b/.gitignore index 83822f3..92635fd 100644 --- a/.gitignore +++ b/.gitignore @@ -2,3 +2,4 @@ /docs-v0.3.3.tar.bz2 /grunt-contrib-nodeunit-0.3.3.tgz /tests-v0.3.3.tar.bz2 +/grunt-contrib-nodeunit-0.4.1.tar.gz diff --git a/dl-tests.sh b/dl-tests.sh deleted file mode 100644 index 4b3a978..0000000 --- a/dl-tests.sh +++ /dev/null @@ -1,25 +0,0 @@ -#!/bin/bash - -tag=v0.3.3 - -set -e - -tmp=$(mktemp -d) - -trap cleanup EXIT -cleanup() { - set +e - [ -z "$tmp" -o ! -d "$tmp" ] || rm -rf "$tmp" -} - -unset CDPATH -pwd=/home/jamie/source/rpmbuild/SOURCES - -pushd "$tmp" -git clone git://github.com/gruntjs/grunt-contrib-nodeunit.git -cd grunt-contrib-nodeunit -git archive --prefix="test/" --format=tar tags/${tag}:test/ \ - | bzip2 > "$pwd"/tests-${tag}.tar.bz2 -git archive --prefix="docs/" --format=tar tags/${tag}:docs/ \ - | bzip2 > "$pwd"/docs-${tag}.tar.bz2 -popd diff --git a/nodejs-grunt-contrib-nodeunit-0.3.3-Gruntfile.js b/nodejs-grunt-contrib-nodeunit-0.3.3-Gruntfile.js deleted file mode 100644 index d3d65c8..0000000 --- a/nodejs-grunt-contrib-nodeunit-0.3.3-Gruntfile.js +++ /dev/null @@ -1,119 +0,0 @@ -/* - * grunt-contrib-nodeunit - * http://gruntjs.com/ - * - * Copyright (c) 2014 "Cowboy" Ben Alman, contributors - * Licensed under the MIT license. - */ - -'use strict'; - -module.exports = function(grunt) { - var path = require('path'); - - // Project configuration. - grunt.initConfig({ - jshint: { - all: [ - 'Gruntfile.js', - 'tasks/*.js', - ], - options: { - jshintrc: '.jshintrc', - }, - }, - - // Unit tests. - nodeunit: { - tests: ['test/*_test.js'], - }, - - // clean tmp dir - clean: { - tests: ['tmp'] - }, - }); - - // Actually load this plugin's task(s). - grunt.loadTasks('tasks'); - - // These plugins provide necessary tasks. - grunt.loadNpmTasks('grunt-contrib-jshint'); - grunt.loadNpmTasks('grunt-contrib-clean'); - grunt.loadNpmTasks('grunt-contrib-internal'); - - // Whenever the "test" task is run, run some basic tests. - grunt.registerTask('test', function(which) { - var test = path.join(__dirname, 'test', 'fixtures', which + '.js'); - if (grunt.file.exists(test)) { - grunt.config('nodeunit.tests', test); - } - grunt.task.run('nodeunit'); - }); - - // Tests nodeunit with tap reporter - grunt.registerTask('test-tap', function(which) { - var test = path.join('test', 'fixtures', which + '.js'); - var tap = path.join('tmp', which + '.js.tap'); - - if (grunt.file.exists(test)) { - grunt.config('nodeunit.tests', test); - } - - grunt.config('nodeunit.options.reporter', 'tap'); - - grunt.task.run('clean'); - grunt.task.run('nodeunit'); - }); - - // Tests nodeunit with tap reporter and output saved to a file - grunt.registerTask('test-tap-out', function(which) { - var test = path.join('test', 'fixtures', which + '.js'); - var tap = path.join('tmp', which + '.js.tap'); - - if (grunt.file.exists(test)) { - grunt.config('nodeunit.tests', test); - } - - grunt.config('nodeunit.options.reporter', 'tap'); - grunt.config('nodeunit.options.reporterOutput', tap); - - grunt.task.run('clean'); - grunt.task.run('nodeunit'); - }); - - // Tests nodeunit with junit reporter - grunt.registerTask('test-junit', function(which) { - var test = path.join('test', 'fixtures', which + '.js'); - var outDir = path.join('tmp', which + '.junit'); - - if (grunt.file.exists(test)) { - grunt.config('nodeunit.tests', test); - } - - grunt.config('nodeunit.options.reporter', 'junit'); - grunt.config('nodeunit.options.reporterOptions', { output: outDir }); - - grunt.task.run('clean'); - grunt.task.run('nodeunit'); - }); - - // Tests nodeunit with minimal reporter - grunt.registerTask('test-minimal', function(which) { - var test = path.join('test', 'fixtures', which + '.js'); - var out = path.join('tmp', which + '.js.out'); - - if (grunt.file.exists(test)) { - grunt.config('nodeunit.tests', test); - } - - grunt.config('nodeunit.options.reporter', 'minimal'); - grunt.config('nodeunit.options.reporterOutput', out); - - grunt.task.run('clean'); - grunt.task.run('nodeunit'); - }); - - // By default, lint and run all tests. - grunt.registerTask('default', ['jshint', 'nodeunit', 'build-contrib']); -}; diff --git a/nodejs-grunt-contrib-nodeunit-junit.patch b/nodejs-grunt-contrib-nodeunit-junit.patch new file mode 100644 index 0000000..bc1acb6 --- /dev/null +++ b/nodejs-grunt-contrib-nodeunit-junit.patch @@ -0,0 +1,32 @@ +commit 95c374348a50bd1b1a07a4f82f7f630d240bf843 +Author: Tom Hughes +Date: Sun Nov 22 00:43:09 2015 +0000 + + Fix test for changes in junit reporter + + I'm not clear why, but the junit reporter seems to report one + error and one failure now instead of two errors. + +diff --git a/test/nodeunit_test.js b/test/nodeunit_test.js +index a5f8cbf..6ef069e 100644 +--- a/test/nodeunit_test.js ++++ b/test/nodeunit_test.js +@@ -62,7 +62,7 @@ exports.nodeunit = { + }); + }, + junit: function(test) { +- test.expect(4); ++ test.expect(5); + grunt.util.spawn({ + grunt: true, + args: ['test-junit:fail', '--no-color'], +@@ -73,7 +73,8 @@ exports.nodeunit = { + var junitContents = grunt.util.normalizelf(grunt.file.read(junitFile)); + + test.ok(junitContents.indexOf('= 19 @@ -39,11 +34,9 @@ BuildRequires: npm(tap) %prep -%setup -q -n package -%setup -q -T -D -a 1 -n package -%setup -q -T -D -a 2 -n package -cp -p %{SOURCE20} ./Gruntfile.js -find docs/ -size 0 -delete +%setup -q -n grunt-contrib-nodeunit-%{version} +%patch0 -p1 +#find docs/ -size 0 -delete %build @@ -66,11 +59,15 @@ cp -pr package.json tasks/ \ %files -%doc LICENSE-MIT README.md docs/ +%doc README.md docs/ +%license LICENSE-MIT %{nodejs_sitelib}/grunt-contrib-nodeunit %changelog +* Sun Nov 22 2015 Tom Hughes - 0.4.1-1 +- update to 0.4.1 upstream release + * Wed Jun 17 2015 Fedora Release Engineering - 0.3.3-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild diff --git a/sources b/sources index 42608be..856464f 100644 --- a/sources +++ b/sources @@ -1,3 +1 @@ -587d5b53e8efecd0b773ab3778e50c14 docs-v0.3.3.tar.bz2 -0882cbb55437d323709c71d363249fa0 grunt-contrib-nodeunit-0.3.3.tgz -db4487907be491d9650694768dc913ca tests-v0.3.3.tar.bz2 +c7f650df8c82ad44f6ad55156b032dac grunt-contrib-nodeunit-0.4.1.tar.gz