Index: tests/phpunit/tests/formatting/SanitizeFileName.php
===================================================================
--- tests/phpunit/tests/formatting/SanitizeFileName.php	(revision 31834)
+++ tests/phpunit/tests/formatting/SanitizeFileName.php	(working copy)
@@ -11,7 +11,7 @@
 	}
 
 	function test_removes_special_chars() {
-		$special_chars = array("?", "[", "]", "/", "\\", "=", "<", ">", ":", ";", ",", "'", "\"", "&", "$", "#", "*", "(", ")", "|", "~", "`", "!", "{", "}", chr(0));
+		$special_chars = array("?", "[", "]", "/", "\\", "=", "<", ">", ":", ";", ",", "'", "\"", "&", "$", "#", "*", "(", ")", "|", "~", "`", "!", "{", "}", "%", "+", chr(0));
 		$string = 'test';
 		foreach ( $special_chars as $char )
 			$string .= $char;
@@ -26,10 +26,10 @@
 	 */
 	function test_replace_spaces() {
 		$urls = array(
-			'unencoded space.png'   => 'unencoded-space.png',
-			'encoded%20space.jpg'   => 'encoded-space.jpg',
-			'plus+space.jpg'        => 'plus-space.jpg',
-			'multi %20 +space.png'   => 'multi-space.png',
+			'unencoded space.png' => 'unencoded-space.png',
+			'encoded-space.jpg' => 'encoded-space.jpg',
+			'plus+space.jpg' => 'plusspace.jpg',
+			'multi %20 +space.png' => 'multi-20-space.png',
 		);
 
 		foreach( $urls as $test => $expected ) {
@@ -49,4 +49,8 @@
 		$this->assertEquals("a-t", sanitize_file_name("a          t"));
 		$this->assertEquals("a-t", sanitize_file_name("a    \n\n\nt"));
 	}
+
+	function test_replaces_percent_sign() {
+		$this->assertEquals("a22b.jpg", sanitize_file_name("a%22b.jpg"));
+	}
 }
