34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
{
OFAutoreleasePool *pool = [[OFAutoreleasePool alloc] init];
OFString *s = @"{\"foo\"\t:\"bar\", \"x\":/*fooo*/ [7.5\r,null//bar\n"
@",\"foo\",false]}";
OFDictionary *d = [OFDictionary dictionaryWithKeysAndObjects:
@"foo", @"bar",
@"x", [OFArray arrayWithObjects:
[OFNumber numberWithFloat: 7.5],
[OFNull null],
@"foo",
[OFNumber numberWithBool: NO],
nil],
nil];
TEST(@"-[JSONValue #1]", [[s JSONValue] isEqual: d])
|
|
|
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
{
OFAutoreleasePool *pool = [[OFAutoreleasePool alloc] init];
OFString *s = @"{\"foo\"\t:\"bar\", \"x\":/*fooo*/ [7.5\r,null//bar\n"
@",\"foo\",false]}";
OFDictionary *d = [OFDictionary dictionaryWithKeysAndObjects:
@"foo", @"bar",
@"x", [OFArray arrayWithObjects:
[OFNumber numberWithFloat: 7.5f],
[OFNull null],
@"foo",
[OFNumber numberWithBool: NO],
nil],
nil];
TEST(@"-[JSONValue #1]", [[s JSONValue] isEqual: d])
|