use specified plc's api
[tests.git] / qaapi / qa / tests / Test.py
index 08f49f1..7a6b496 100644 (file)
@@ -30,7 +30,8 @@ class Test:
        """
        return True
 
-    def __init__(self, config = Config()):
+    def __init__(self, config = None):
+        if config is None: config = Config()
        self.name = self.__class__.__name__
        self.path=os.path.abspath(os.path.dirname(sys.argv[0]))
        self.config = config
@@ -50,14 +51,7 @@ class Test:
 
        module = self.__class__.__module__.replace(".", os.sep)
        file = self.path + os.sep + module + ".py"
-       try:
-           result = self.call(*args, **kwds)
-       except NameError:
-           command = "%s %s" % (file, " ".join(args))
-           utils.header(command)
-           (stdout, stderr) = utils.popen(command)
-           print "".join(stdout)
-           result = None
+       result = self.call(*args, **kwds)
  
        return result