MediaWiki
REL1_24
|
Public Member Functions | |
testDecodeReturnType () | |
testEncodeAllOk ($from, $to) | |
provideEncodeAllOk | |
testEncodeDefault ($from, $to) | |
provideEncodeDefault | |
testEncodePhpBug46944 () | |
testEncoderPrettyPrinting ($pretty, $expectedIndent) | |
provideEncoderPrettyPrinting | |
testEncodeUtf8 ($from, $to) | |
provideEncodeUtf8 | |
testEncodeXmlMeta ($from, $to) | |
provideEncodeXmlMeta | |
testParse ($value) | |
provideParse | |
testParseErrors ($value) | |
provideParseErrors | |
testParseTryFixing ($value, $expected) | |
provideParseTryFixing | |
Static Public Member Functions | |
static | provideEncodeAllOk () |
static | provideEncodeDefault () |
static | provideEncoderPrettyPrinting () |
static | provideEncodeUtf8 () |
static | provideEncodeXmlMeta () |
static | provideParse () |
static | provideParseErrors () |
static | provideParseTryFixing () |
static | toObject ($value) |
Recursively convert arrays into stdClass. | |
Static Private Member Functions | |
static | getEncodeTestCases (array $unescapedGroups) |
Generate a set of test cases for a particular combination of encoder options. |
Definition at line 6 of file FormatJsonTest.php.
static FormatJsonTest::getEncodeTestCases | ( | array $ | unescapedGroups | ) | [static, private] |
Generate a set of test cases for a particular combination of encoder options.
array | $unescapedGroups | List of character groups to leave unescaped |
Definition at line 231 of file FormatJsonTest.php.
References $from, $name, array(), and as.
Referenced by provideEncodeAllOk(), provideEncodeDefault(), provideEncodeUtf8(), and provideEncodeXmlMeta().
static FormatJsonTest::provideEncodeAllOk | ( | ) | [static] |
Definition at line 93 of file FormatJsonTest.php.
References array(), and getEncodeTestCases().
static FormatJsonTest::provideEncodeDefault | ( | ) | [static] |
Definition at line 60 of file FormatJsonTest.php.
References array(), and getEncodeTestCases().
static FormatJsonTest::provideEncoderPrettyPrinting | ( | ) | [static] |
Definition at line 8 of file FormatJsonTest.php.
References array().
static FormatJsonTest::provideEncodeUtf8 | ( | ) | [static] |
Definition at line 71 of file FormatJsonTest.php.
References array(), and getEncodeTestCases().
static FormatJsonTest::provideEncodeXmlMeta | ( | ) | [static] |
Definition at line 82 of file FormatJsonTest.php.
References array(), and getEncodeTestCases().
static FormatJsonTest::provideParse | ( | ) | [static] |
Definition at line 126 of file FormatJsonTest.php.
References array().
static FormatJsonTest::provideParseErrors | ( | ) | [static] |
Definition at line 208 of file FormatJsonTest.php.
References array().
static FormatJsonTest::provideParseTryFixing | ( | ) | [static] |
Definition at line 172 of file FormatJsonTest.php.
References array().
Definition at line 112 of file FormatJsonTest.php.
References FormatJson\decode().
FormatJsonTest::testEncodeAllOk | ( | $ | from, |
$ | to | ||
) |
provideEncodeAllOk
Definition at line 100 of file FormatJsonTest.php.
References $from, FormatJson\ALL_OK, and FormatJson\encode().
FormatJsonTest::testEncodeDefault | ( | $ | from, |
$ | to | ||
) |
provideEncodeDefault
Definition at line 67 of file FormatJsonTest.php.
References $from, and FormatJson\encode().
Definition at line 104 of file FormatJsonTest.php.
References FormatJson\encode().
FormatJsonTest::testEncoderPrettyPrinting | ( | $ | pretty, |
$ | expectedIndent | ||
) |
provideEncoderPrettyPrinting
Definition at line 23 of file FormatJsonTest.php.
References array(), and FormatJson\encode().
FormatJsonTest::testEncodeUtf8 | ( | $ | from, |
$ | to | ||
) |
provideEncodeUtf8
Definition at line 78 of file FormatJsonTest.php.
References $from, FormatJson\encode(), and FormatJson\UTF8_OK.
FormatJsonTest::testEncodeXmlMeta | ( | $ | from, |
$ | to | ||
) |
provideEncodeXmlMeta
Definition at line 89 of file FormatJsonTest.php.
References $from, FormatJson\encode(), and FormatJson\XMLMETA_OK.
FormatJsonTest::testParse | ( | $ | value | ) |
provideParse
mixed | $value |
Definition at line 156 of file FormatJsonTest.php.
References $value, FormatJson\ALL_OK, MediaWikiTestCase\assertType(), FormatJson\encode(), FormatJson\FORCE_ASSOC, FormatJson\parse(), and toObject().
FormatJsonTest::testParseErrors | ( | $ | value | ) |
provideParseErrors
mixed | $value |
Definition at line 219 of file FormatJsonTest.php.
References $value, MediaWikiTestCase\assertType(), and FormatJson\parse().
FormatJsonTest::testParseTryFixing | ( | $ | value, |
$ | expected | ||
) |
provideParseTryFixing
string | $value | |
string | bool | $expected |
Definition at line 195 of file FormatJsonTest.php.
References $value, FormatJson\ALL_OK, MediaWikiTestCase\assertType(), FormatJson\encode(), FormatJson\parse(), and FormatJson\TRY_FIXING.
static FormatJsonTest::toObject | ( | $ | value | ) | [static] |
Recursively convert arrays into stdClass.
array | string | bool | int | float | null | $value |
Definition at line 148 of file FormatJsonTest.php.
References $value, and object.
Referenced by testParse().