From a28983086ee91b19200c47fadc6bc3ba58a0fcb9 Mon Sep 17 00:00:00 2001 From: Scott González Date: Wed, 18 Apr 2012 22:36:15 -0400 Subject: Tests: Lint. --- tests/unit/subsuiteRunner.js | 26 ++++++++++++++++---------- 1 file changed, 16 insertions(+), 10 deletions(-) (limited to 'tests/unit/subsuiteRunner.js') diff --git a/tests/unit/subsuiteRunner.js b/tests/unit/subsuiteRunner.js index ddfccc7c1..2d6de2de1 100644 --- a/tests/unit/subsuiteRunner.js +++ b/tests/unit/subsuiteRunner.js @@ -4,13 +4,16 @@ var subsuiteFrame; QUnit.extend( QUnit, { testSuites: function( suites ) { + function generateSuite( suite ) { + asyncTest( suite, function() { + QUnit.runSuite( suite ); + }); + } + for ( var i = 0; i < suites.length; i++ ) { - (function( suite ) { - asyncTest( suite, function() { - QUnit.runSuite( suite ); - }); - }( suites[i] ) ); + generateSuite( suites[ i ] ); } + QUnit.done = function() { subsuiteFrame.style.display = "none"; }; @@ -23,10 +26,12 @@ QUnit.extend( QUnit, { testDone: function() { var current = QUnit.id( this.config.current.id ), - children = current.children; + children = current.children, + i = 0, + length = children.length; // undo the auto-expansion of failed tests - for ( var i = 0; i < children.length; i++ ) { + for ( ; i < length; i++ ) { if ( children[i].nodeName === "OL" ) { children[i].style.display = "none"; } @@ -34,10 +39,11 @@ QUnit.extend( QUnit, { }, runSuite: function( suite ) { - var body = document.getElementsByTagName( "body" )[0], - iframe = subsuiteFrame = document.createElement( "iframe" ), - iframeWin; + var iframeWin, + body = document.getElementsByTagName( "body" )[0], + iframe = document.createElement( "iframe" ); + subsuiteFrame = iframe; iframe.className = "qunit-subsuite"; body.appendChild( iframe ); -- cgit v1.2.3 ble'>4.2-stable Mirror of redmine code source: https://github.com/redmine/redminewww-data
summaryrefslogtreecommitdiffstats
path: root/app/views/issue_categories/show.api.rsb
blob: cefa7c8b8b88fe89974040cf7eef48a0bd2db776 (plain)
1
2
3
4
5
6