Exemplo n.º 1
0
 def setup_class(cls):
     cls.Log = Logger()
     cls.Log.info(u"========%s测试开始:========" % __class__.__name__)
     cls.ws = WsSingle(url)
Exemplo n.º 2
0
 def setup_class(cls):
     cls.now = time.strftime('%Y-%m-%d-%H-%M-%S')
     cls.Log = Logger()
     cls.Log.info(u"========%s测试开始:========" % __class__.__name__)
     cls.ws=WsSingle(url)
Exemplo n.º 3
0
from common.conf import Conf
from common.m_process import mprocess
import Project_path
import ssl, json
from common.read_xls_news import Read_xls
from common.changeChineseNumToArab import changeChineseNumToArab

xls = "D:\\Users\\lijq36\\Desktop\\8009.xls"
xls_new = "E:\\AITEST\\TestResult\\8009.xls"
r = Read_xls(xls)
w = r.copy_book()

ssl._create_default_https_context = ssl._create_unverified_context
conf_path = Project_path.conf_path
url = Conf(conf_path + "/ws.ini").get_value("WS", "url")
ws = WsSingle(url)
wav_path = "E:\\8009项目\\019"
wav_list = traversing_path.file_all_path(wav_path, file_type="wav")
print(wav_list)


def test(wav):
    wav_name = wav.split('.')[0].split('\\')[-1]
    a = ws.runsingle(wav)
    result = json.loads(a)
    print(wav_name, result['text'].replace(' ', ""))


if __name__ == '__main__':
    mprocess(test, wav_list)
    ws.close()