Browse Source

Tell run-ci that Travis can run postgres tests

Hamilton Turner 11 years ago
parent
commit
6760645612
1 changed files with 3 additions and 2 deletions
  1. 3 2
      toolset/run-ci.py

+ 3 - 2
toolset/run-ci.py

@@ -45,6 +45,7 @@ class CIRunnner:
       osvalidtests = [t for t in dirtests if t.os.lower() == "linux"
       osvalidtests = [t for t in dirtests if t.os.lower() == "linux"
                     and (t.database_os.lower() == "linux" or t.database_os.lower() == "none")]
                     and (t.database_os.lower() == "linux" or t.database_os.lower() == "none")]
       validtests = [t for t in osvalidtests if t.database.lower() == "mysql"
       validtests = [t for t in osvalidtests if t.database.lower() == "mysql"
+                    or t.database.lower() == "postgres"
                     or t.database.lower() == "none"]
                     or t.database.lower() == "none"]
       log.info("Found %s tests (%s for linux, %s for linux and mysql) in directory '%s'", 
       log.info("Found %s tests (%s for linux, %s for linux and mysql) in directory '%s'", 
         len(dirtests), len(osvalidtests), len(validtests), test_directory)
         len(dirtests), len(osvalidtests), len(validtests), test_directory)
@@ -54,8 +55,8 @@ class CIRunnner:
           log.critical("Note: Found tests that could run in Travis-CI if more databases were supported")
           log.critical("Note: Found tests that could run in Travis-CI if more databases were supported")
         sys.exit(1)
         sys.exit(1)
       
       
-      # Prefer mysql tests over 'none' if we have both
-      preferred = [t for t in validtests if t.database.lower() == "mysql"]
+      # Prefer database tests over 'none' if we have both
+      preferred = [t for t in validtests if t.database.lower() != "none"]
       if len(preferred) > 0:
       if len(preferred) > 0:
         self.test = preferred[0]
         self.test = preferred[0]
       else:
       else: