r69464 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r69463‎ | r69464 | r69465 >
Date:03:00, 17 July 2010
Author:jeroendedauw
Status:deferred
Tags:
Comment:
Added tests
Modified paths:
  • /trunk/extensions/Maps/test/MapsCoordinateParserTest.php (modified) (history)

Diff [purge]

Index: trunk/extensions/Maps/test/MapsCoordinateParserTest.php
@@ -54,7 +54,9 @@
5555
5656 public static $coordinateMappings = array(
5757 'float-dms' => array(
58 - '42° 30\' 0", -42° 30\' 0"' => array( '42.5, -42.5', '42.5 N, 42.5 W' )
 58+ '42° 30\' 0", -42° 30\' 0"' => array( '42.5, -42.5', '42.5 N, 42.5 W' ),
 59+ '-42° 30\' 0", 42° 30\' 0"' => array( '-42.5, 42.5', '42.5 S, 42.5 E' ),
 60+ '42° 25\' 27", 42° 25\' 27"' => array( '42.4242, 42.4242', '42.4242 N, 42.4242 E' ),
5961 ),
6062 );
6163
@@ -142,7 +144,7 @@
143145 /**
144146 * @dataProvider coordinatesProvider
145147 */
146 - public function testAreCoordinates( $coord ) {
 148+ public function testAreCoordinates() {
147149 foreach( self::$coordinates as $coordsOfType ) {
148150 foreach( $coordsOfType as $coord ) {
149151 $this->assertTrue( MapsCoordinateParser::areCoordinates( $coord ), "$coord not recognized as coordinate." );
@@ -239,7 +241,7 @@
240242 $this->assertEquals(
241243 $destination,
242244 $result,
243 - "$source parsed to $result, not $destination"
 245+ "$source parsed to \n$result, not \n$destination."
244246 );
245247 }
246248 }

Status & tagging log