Skip to content
Snippets Groups Projects
Commit 3c34fb8a authored by Clemens Berteld's avatar Clemens Berteld
Browse files

Minor changes

parent c612a4ca
No related branches found
No related tags found
No related merge requests found
......@@ -25,8 +25,9 @@ param_postgres = cfg["POSTGRES"]
stationList = None
testDB = 'weathertestdb'
class TestExportToDatabase(unittest.TestCase):
def testDBExists(self):
print("__Test DB Exists")
......@@ -75,15 +76,13 @@ class TestExportToDatabase(unittest.TestCase):
# with psycopg2.connect(database="postgres", user=param_postgres["user"], password=param_postgres["password"], host=param_postgres["host"], port=param_postgres["port"]) as connection:
# connection.set_isolation_level(ISOLATION_LEVEL_AUTOCOMMIT)
# with connection.cursor() as cursor:
self.assertTrue(check)
print("Test OKAY__")
except(Exception, psycopg2.DatabaseError) as error:
self.assertRaises(error)
print("Test FAILED__")
def testForStationExistence(self):
print("__Test Check for Table Existence")
# given
......@@ -103,10 +102,7 @@ class TestExportToDatabase(unittest.TestCase):
connection.close()
self.assertTrue(check)
def testCreateTable(self):
print("__Test CreateTable")
try:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment