Browse Source

* Correct a test for mysql version 5 (server)

git-svn-id: trunk@10821 -
joost 17 years ago
parent
commit
3120184b2a

+ 1 - 1
packages/fcl-db/tests/dbtestframework.pas

@@ -12,7 +12,7 @@ uses
   DigestTestReport,
   DigestTestReport,
   toolsunit,
   toolsunit,
 // Units wich contains the tests
 // Units wich contains the tests
-  testbasics, testfieldtypes, TestDatasources, testdbbasics;
+{  testbasics, testfieldtypes, TestDatasources,} testdbbasics;
   
   
 var
 var
   FXMLResultsWriter: TXMLResultsWriter;
   FXMLResultsWriter: TXMLResultsWriter;

+ 2 - 2
packages/fcl-db/tests/testfieldtypes.pas

@@ -292,8 +292,8 @@ begin
     Open;
     Open;
     for i := 0 to testValuesCount-1 do
     for i := 0 to testValuesCount-1 do
       begin
       begin
-      if (SQLDbType in MySQLdbTypes) then
-        AssertEquals(TrimRight(testValues[i]),fields[0].AsString) // MySQL automatically trims strings
+      if (SQLDbType in [mysql40,mysql41]) then
+        AssertEquals(TrimRight(testValues[i]),fields[0].AsString) // MySQL < 5.0.3 automatically trims strings
       else
       else
         AssertEquals(testValues[i],fields[0].AsString);
         AssertEquals(testValues[i],fields[0].AsString);
       Next;
       Next;