Update test_passwd.py
This commit is contained in:
parent
f97e42e957
commit
b929a73526
|
@ -1,4 +1,5 @@
|
||||||
import os
|
import os
|
||||||
|
import platform
|
||||||
import subprocess
|
import subprocess
|
||||||
from frame.log import *
|
from frame.log import *
|
||||||
from frame.cases import *
|
from frame.cases import *
|
||||||
|
@ -25,6 +26,12 @@ class TDTestCase(TBase):
|
||||||
def run(self):
|
def run(self):
|
||||||
apiPath = self.apiPath()
|
apiPath = self.apiPath()
|
||||||
tdLog.info(f"api path: {apiPath}")
|
tdLog.info(f"api path: {apiPath}")
|
||||||
|
if platform.system().lower() == 'linux':
|
||||||
|
p = subprocess.Popen(f"cd {apiPath} && make", shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
||||||
|
out, err = p.communicate()
|
||||||
|
if 0 != p.returncode:
|
||||||
|
tdLog.exit("Test script passwdTest.c make failed")
|
||||||
|
|
||||||
p = subprocess.Popen(f"ls {apiPath}", shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
p = subprocess.Popen(f"ls {apiPath}", shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
||||||
out, err = p.communicate()
|
out, err = p.communicate()
|
||||||
tdLog.info(f"test files: {out}")
|
tdLog.info(f"test files: {out}")
|
||||||
|
|
Loading…
Reference in New Issue