Commit f7d5631c authored by libin's avatar libin
Browse files

20190819

parent 57a1eabe
......@@ -31,7 +31,7 @@ DYNAMIC_WARNING_MSG ='.ant-message-custom-content.ant-message-error>span'
NOT_SAME_PASSWORD = '.ant-form-explain'
#编辑
ADMINSTRATOR_EDIT_BUTTON = ".ant-table-tbody tr:nth-last-child(1) td:nth-child(4) i:nth-child(1)"
ADMINSTRATOR_EDIT_BUTTON = ".ant-table-row:last-child td:first-child i:nth-child(1)"
ADMINSTRATOR_EDIT_NAME_INPUT = "html/body/div[2]/div/div[2]/div/div[1]/div[2]/ul/li[1]/div/input"
ADMINSTRATOR_EDIT_URL_INPUT = "html/body/div[2]/div/div[2]/div/div[1]/div[2]/ul/li[2]/div/input"
TITLE_EDIT_COMPANY = '.ant-modal-title'
......@@ -43,7 +43,7 @@ ASSERT_EDIT_ERROR = ".ant-message-custom-content.ant-message-error>span"
TEXT_NAME_LINE_ONE = ".//*[@id='main']/div/div[2]/div[2]/div/div/div/div/div/div/table/tbody/tr[last()]/td[2]"
TEXT_URL_LINE_ONE = ".//*[@id='main']/div/div[2]/div[2]/div/div/div/div/div/div/table/tbody/tr[last()]/td[3]"
#删除
ADMINSTRATOR_DELETE_BUTTON = ".ant-table-tbody tr:nth-last-child(1) td:nth-child(4) i:nth-child(2)"
ADMINSTRATOR_DELETE_BUTTON = ".ant-table-row:last-child td:first-child i:nth-child(2)"
CHANCLE_DELETE_BUTTON = ".ant-confirm-btns button:nth-child(1)"
ENSURE_DELETE_BUTTON = ".ant-confirm-btns button:nth-child(2)"
ASSERT_DELETE_TEXT = ".ant-confirm-content"
......
......@@ -18,6 +18,8 @@ class EditCompany(unittest.TestCase):
def setUp(self):
self.object = web_client.WebClient(test_data.MANAGE_URL)
deal_sql = "delete from `domain` where domainName like '%qwe%'"
deal_db_data.execute_sql(deal_sql)
login_swp.login01(self.object, test_data.SUPERADMIN_NAME, test_data.SUPERADMIN_PW,test_data.HOME_PAGE_SUPERADMIN_NAME)
time.sleep(2)
#创建企业域
......
......@@ -18,8 +18,9 @@ class PageTurning(unittest.TestCase):
sql_obj.executeSQL(r"SELECT COUNT(*) FROM `domain` WHERE domainStatus=0")
result = sql_obj.result[0][0]
while result < 11:
randStr = ''.join(random.sample(['a','b','c','d','e','f'],4))
sql_obj.executeSQL(r'''INSERT INTO `domain`(canceTime,delayedTime,domainName,domainStatus,domainUrl,fixedColor)
VALUES(30,30,'%s',0,'%s',0)''' % (random.choice('abcdefgh', 4), random.choice('abcdefgh', 4) + ".com"))
VALUES(30,30,'%s',0,'%s',0)''' % (randStr, randStr + ".com"))
sql_obj.commitSQL()
result = result + 1
sql_obj.close_connect()
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment