Opened 4 years ago

Closed 4 years ago

#499 closed defect (fixed)

Import script for Multipoint test dataset to use common systemtest configuration

Reported by: pcampalani Owned by: arezaeim
Priority: major Milestone: 9.0
Component: systemtest Version: 8.5
Keywords: multipoint import Cc:
Complexity: Easy


The python script used to ingest the test multipoint dataset for the systemtests is now using own configuration variables to connect to the petascopedb.
Instead, it need to take that information from the common configuration file of the systemtest, which is ./systemtest/conf/test.cfg.


FIXME file:

PROBLEM: duplicated configuration variables:
 13 DB_NAME = "petascopedb"
 14 HOST_NAME = "localhost"
 15 USER_NAME = "petauser"
 16 PASSW = "petapasswd"

FIX: do not assign their value as string inside the .py file, like "petauser", but instead fetch the info from THE configuration file of the systemtest suites, which is:


SOLUTION: test.cfg *exports* the variables in the user environment, so the script should simply read them with python libraries.
Should be straightforward with `os' package:

    import os
    DB_NAME = os.environ['PS_DB']

Change History (3)

comment:1 Changed 4 years ago by dmisev

Also is it possible to get rid of psycopg? Can't we just stick to use psql, it works well for everything else.

comment:2 Changed 4 years ago by dmisev

Shouldn't this be closed btw?

comment:3 Changed 4 years ago by dmisev

  • Resolution set to fixed
  • Status changed from new to closed

Alireza please close your tickets when you fix them...


Note: See TracTickets for help on using tickets.