Henning Snater has uploaded a new change for review. https://gerrit.wikimedia.org/r/142522
Change subject: Removed obsolete QUnit tests ...................................................................... Removed obsolete QUnit tests Corresponding JS parsers have been removed in I2634b82498aa6bc6b7fab9cbd81cbecede3d9d34. Change-Id: I4982e05d583b96819e247b09013e1b3db849584f --- M lib/WikibaseLib.hooks.php D lib/tests/qunit/parsers/GlobeCoordinateParser.tests.js D lib/tests/qunit/parsers/QuantityParser.tests.js 3 files changed, 0 insertions(+), 177 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/22/142522/1 diff --git a/lib/WikibaseLib.hooks.php b/lib/WikibaseLib.hooks.php index 11bcb5c..1daa765 100644 --- a/lib/WikibaseLib.hooks.php +++ b/lib/WikibaseLib.hooks.php @@ -277,35 +277,6 @@ ), ); - $testModules['qunit']['wikibase.parsers.GlobeCoordinateParser.tests'] = $moduleBase + array( - 'scripts' => array( - 'tests/qunit/wikibase.tests.js', - 'tests/qunit/parsers/GlobeCoordinateParser.tests.js', - ), - 'dependencies' => array( - 'dataValues.values', - 'globeCoordinate.js', - 'util.inherit', - 'valueParsers.tests', - 'wikibase.GlobeCoordinateParser', - 'wikibase.tests.qunit.testrunner', - ), - ); - - $testModules['qunit']['wikibase.parsers.QuantityParser.tests'] = $moduleBase + array( - 'scripts' => array( - 'tests/qunit/wikibase.tests.js', - 'tests/qunit/parsers/QuantityParser.tests.js', - ), - 'dependencies' => array( - 'dataValues.values', - 'util.inherit', - 'valueParsers.tests', - 'wikibase.QuantityParser', - 'wikibase.tests.qunit.testrunner', - ), - ); - return true; } } diff --git a/lib/tests/qunit/parsers/GlobeCoordinateParser.tests.js b/lib/tests/qunit/parsers/GlobeCoordinateParser.tests.js deleted file mode 100644 index 2ddf56a..0000000 --- a/lib/tests/qunit/parsers/GlobeCoordinateParser.tests.js +++ /dev/null @@ -1,51 +0,0 @@ -/** - * @licence GNU GPL v2+ - * @author H. Snater < mediaw...@snater.com > - */ -( function( wb, vp, dv, GlobeCoordinate, util ) { - 'use strict'; - - var PARENT = vp.tests.ValueParserTest; - - /** - * Constructor for creating a test object holding tests for the GlobeCoordinateParser. - * - * @constructor - * @extends valueParsers.tests.ValueParserTest - * @since 0.1 - */ - wb.tests.GlobeCoordinateParserTest = util.inherit( PARENT, { - - /** - * @see vp.tests.ValueParserTest.getConstructor - */ - getConstructor: function() { - return wb.GlobeCoordinateParser; - }, - - /** - * @see vp.tests.ValueParserTest.getParseArguments - */ - getParseArguments: function() { - return [ - [ - '1.5, 1.25', - new dv.GlobeCoordinateValue( new GlobeCoordinate( - { latitude: 1.5, longitude: 1.25, precision: 0.01 } - ) ) - ], - [ - '-50, -20', - new dv.GlobeCoordinateValue( new GlobeCoordinate( - { latitude: -50, longitude: -20, precision: 1 } - ) ) - ] - ]; - } - - } ); - - var test = new wb.tests.GlobeCoordinateParserTest(); - test.runTests( 'valueParsers.GlobeCoordinateParser' ); - -}( wikibase, valueParsers, dataValues, globeCoordinate.GlobeCoordinate, util ) ); diff --git a/lib/tests/qunit/parsers/QuantityParser.tests.js b/lib/tests/qunit/parsers/QuantityParser.tests.js deleted file mode 100644 index 2c873da..0000000 --- a/lib/tests/qunit/parsers/QuantityParser.tests.js +++ /dev/null @@ -1,97 +0,0 @@ -/** - * @licence GNU GPL v2+ - * @author Daniel Werner < daniel.a.r.wer...@gmail.com > - */ -( function( wb, vp, DecimalValue, QuantityValue, util ) { - 'use strict'; - - var PARENT = vp.tests.ValueParserTest; - - wb.tests.QuantityParserTest = util.inherit( PARENT, { - /** - * @see vp.tests.ValueParserTest.getConstructor - */ - getConstructor: function() { - return wb.QuantityParser; - }, - - /** - * @see vp.tests.ValueParserTest.getParseArguments - */ - getParseArguments: function() { - return [ - [ - '+0!', - new QuantityValue( - new DecimalValue( 0 ), - '1', - new DecimalValue( 0 ), - new DecimalValue( 0 ) - ) - ], [ - '+1!', - new QuantityValue( - new DecimalValue( 1 ), - '1', - new DecimalValue( 1 ), - new DecimalValue( 1 ) - ) - ], [ - '+1.5!', - new QuantityValue( - new DecimalValue( 1.5 ), - '1', - new DecimalValue( 1.5 ), - new DecimalValue( 1.5 ) - ) - ], [ - '-2!', - new QuantityValue( - new DecimalValue( -2 ), - '1', - new DecimalValue( -2 ), - new DecimalValue( -2 ) - ) - ], [ - '+100000000000000000000000000000!', - new QuantityValue( - new DecimalValue( 100000000000000000000000000000 ), - '1', - new DecimalValue( 100000000000000000000000000000 ), - new DecimalValue( 100000000000000000000000000000 ) - ) - ] -/* TODO: Activate after bug #56682 has been fixed - , [ - '0+-1', - new QuantityValue( - new DecimalValue( 0 ), - '1', - new DecimalValue( -1 ), - new DecimalValue( 1 ) - ) - ], [ - '0±1', - new QuantityValue( - new DecimalValue( 0 ), - '1', - new DecimalValue( -1 ), - new DecimalValue( 1 ) - ) - ] -*/ - ]; - } - - } ); - - var test = new wb.tests.QuantityParserTest(); - test.runTests( 'valueParsers.QuantityParser' ); - -}( - wikibase, - valueParsers, - dataValues.DecimalValue, - dataValues.QuantityValue, - util -) ); -- To view, visit https://gerrit.wikimedia.org/r/142522 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I4982e05d583b96819e247b09013e1b3db849584f Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: master Gerrit-Owner: Henning Snater <henning.sna...@wikimedia.de> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits