From ef7516e896df51af8b39a711ae5fe233176ded39 Mon Sep 17 00:00:00 2001 From: stuconnolly Date: Sun, 26 May 2013 18:29:36 +0000 Subject: Output test details in order to debug in build server. --- Frameworks/PostgresKit/Tests/PGPostgresResultTests.m | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'Frameworks/PostgresKit') diff --git a/Frameworks/PostgresKit/Tests/PGPostgresResultTests.m b/Frameworks/PostgresKit/Tests/PGPostgresResultTests.m index 5553cd75..8ce17c10 100644 --- a/Frameworks/PostgresKit/Tests/PGPostgresResultTests.m +++ b/Frameworks/PostgresKit/Tests/PGPostgresResultTests.m @@ -47,6 +47,23 @@ - (void)testResultDescriptionIsCorrect { + NSLog(@"actual = %@", [[[_result description] stringByReplacingOccurrencesOfString:@"\n" withString:@""] stringByReplacingOccurrencesOfString:@" " withString:@""]); + NSLog(@"expected = %@", @"{" + "\"bigint_field\" = 123456789;" + "\"bool_field\" = 1;" + "\"char_field\" = CHAR;" + "\"date_field\" = \"1987-04-08 00:00:00 +0100\";" + "\"float_field\" = \"12345.68\";" + "\"int_field\" = 12345;" + "\"numeric_field\" = \"12345.678\";" + "\"smallint_field\" = 2;" + "\"time_field\" = \"2000-01-01 02:02:02 +0000\";" + "\"timestamp_field\" = \"1987-04-08 03:02:02 +0100\";" + "\"timestamptz_field\" = \"8 Apr 1987 03:02:02 GMT+01:00\";" + "\"timetz_field\" = \"02:02:02 GMT+10:00\";" + "\"varchar_field\" = VARCHAR;" + "}"); + // Compare the output after getting rid of newlines and spaces STAssertTrue([[[[_result description] stringByReplacingOccurrencesOfString:@"\n" withString:@""] stringByReplacingOccurrencesOfString:@" " withString:@""] isEqualToString:@"{" "\"bigint_field\" = 123456789;" -- cgit v1.2.3