Data-Test-Executer Framework speziell zum Test von Datenverarbeitungen mit Datengenerierung, Systemvorbereitungen, Einspielungen, ganzheitlicher diversifizierender Vergleich
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

53 lines
1.8 KiB

import unittest
import inspect
import basic.constants as B
import basic.toolHandling as toolHandling
import tools.data_const as D
import test.testtools
import test.constants
import basic.program
import os
import tools.data_tool
HOME_PATH = test.constants.HOME_PATH
DATA_PATH = test.constants.DATA_PATH
OS_SYSTEM = test.constants.OS_SYSTEM
"""
a) catalog: key(s) - values # meta-spec, meta-auto
b) head: key - value # spec-info
c) option: key - value # spec -> job.par
d) step: key=function - values # spec (tp, ts) -> comp.function
e) step: key=usecase - values # spec (tc) -> comp.steps
f) ddl-table: key=field - vaulues=attributes # meta-spec, comp
g) data-table: array: field - values # spec.data, comp.artifacts
"""
# the list of TEST_FUNCTIONS defines which function will be really tested.
# if you minimize the list you can check the specific test-function
TEST_FUNCTIONS = ["test_01getKeyword"]
PROGRAM_NAME = "clean_workspace"
# with this variable you can switch prints on and off
verbose = False
class MyTestCase(unittest.TestCase):
mymsg = "--------------------------------------------------------------"
def test_01getKeyword(self):
global mymsg
actfunction = str(inspect.currentframe().f_code.co_name)
cnttest = 0
if actfunction not in TEST_FUNCTIONS:
return
# job = basic.program.SimpleJob(PROGRAM_NAME)
#job = test.testtools.getWorkspaceJob(PROGRAM_NAME)
for x in ["_variants", "_variant", "subtable:_variants", "subtable:variants"]:
res = tools.data_tool.getPurKeyword(x)
self.assertEqual(res, "variant")
def test_zzz(self):
print(MyTestCase.mymsg)
if __name__ == '__main__':
unittest.main()