Update of /cvsroot/pgsqlformac/pgCocoaDB/UnitTest
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19764/UnitTest
Modified Files:
pgCocoaDBSchemaTest.m
Log Message:
Fix round trip function SQL.
Index: pgCocoaDBSchemaTest.m
===================================================================
RCS file: /cvsroot/pgsqlformac/pgCocoaDB/UnitTest/pgCocoaDBSchemaTest.m,v
retrieving revision 1.19
retrieving revision 1.20
diff -C2 -d -r1.19 -r1.20
*** pgCocoaDBSchemaTest.m 14 Sep 2006 12:26:46 -0000 1.19
--- pgCocoaDBSchemaTest.m 30 Oct 2006 19:30:32 -0000 1.20
***************
*** 21,25 ****
NSString* const PGCocoaTestPassword = @"";
NSString* const PGCocoaTestHost = @"localhost";
! NSString* const PGCocoaTestPort = @"5433";
// Uncomment the following line to automatically drop and recreate the test database.
--- 21,25 ----
NSString* const PGCocoaTestPassword = @"";
NSString* const PGCocoaTestHost = @"localhost";
! NSString* const PGCocoaTestPort = @"5432";
// Uncomment the following line to automatically drop and recreate the test database.
***************
*** 163,167 ****
[conn execQuery:sql];
STAssertTrue([conn errorDescription] == nil, @"Error executing SQL: %@. %@", sql, [conn errorDescription]);
!
sql = [NSString stringWithFormat:@"%s%@.%@.%s%@.%@.%s", "CREATE TRIGGER create_timestamp BEFORE INSERT ON ",
--- 163,176 ----
[conn execQuery:sql];
STAssertTrue([conn errorDescription] == nil, @"Error executing SQL: %@. %@", sql, [conn errorDescription]);
!
! sql = [NSString stringWithFormat:@"%s%@.%@.%s", "CREATE or REPLACE FUNCTION ", PGCocoaTestDatabase, PGCocoaTestSchema,
! "a_sum(x int, y int) RETURNS int AS $$\nDECLARE\n result int; \nBEGIN\n result := x + y;\n RETURN result;\nEND;\n$$ LANGUAGE plpgsql;\n"];
! [conn execQuery:sql];
! STAssertTrue([conn errorDescription] == nil, @"Error executing SQL: %@. %@", sql, [conn errorDescription]);
!
! sql = [NSString stringWithFormat:@"%s%@.%@.%s", "CREATE or REPLACE FUNCTION ", PGCocoaTestDatabase, PGCocoaTestSchema,
! "do_nothing(x int, y int) RETURNS void AS $$\nDECLARE\n result int; \nBEGIN\n result := x + y;\nEND;\n$$ LANGUAGE plpgsql;\n"];
! [conn execQuery:sql];
! STAssertTrue([conn errorDescription] == nil, @"Error executing SQL: %@. %@", sql, [conn errorDescription]);
sql = [NSString stringWithFormat:@"%s%@.%@.%s%@.%@.%s", "CREATE TRIGGER create_timestamp BEFORE INSERT ON ",
|