Пример #1
0
 def test_tc002051(self,init_contract_type_data):
     contract_type_id = init_contract_type_data
     contractType.modify(contract_type_id,name="房屋出租合同")
     for contract_type in contractType.list(self.payload):
         if contract_type_id == contract_type["_id"]:
             assert "房屋出租合同" == contract_type["name"]
             break
Пример #2
0
 def test_tc002002(self):
     with allure.step("创建合同"):
         self.ret_add_contract_type = contractType.add(name="笔记本售卖合同",code="BJB20200917520")
         for contract_type in contractType.list(self.payload):
             if self.ret_add_contract_type["_id"] == contract_type["_id"]:
                 assert "笔记本售卖合同" == contract_type["name"]
                 break
Пример #3
0
 def test_tc002001(self):
     with allure.step("增加合同类型"):
         self.ret_add_contract_type = contractType.add(name="出租合同",
                                                       code="CZ20200925001")
         ret_list_contract_type = contractType.list(self.payload)
         for contract_type in ret_list_contract_type:
             if self.ret_add_contract_type["_id"] == contract_type["_id"]:
                 assert self.ret_add_contract_type["name"] == contract_type[
                     "name"]
                 break
Пример #4
0
 def test_tc002092(self):
     ret_list_contract_type_before = contractType.list(self.payload)
     contractType.delete("test_midify")
     ret_list_contract_type_after = contractType.list(self.payload)
     assert ret_list_contract_type_before == ret_list_contract_type_after
Пример #5
0
 def test_tc002091(self, before_tc002091):
     contract_type_id = before_tc002091
     with allure.step("删除合同类型"):
         contractType.delete(contract_type_id)
         print(contractType.list(self.payload))
         assert contractType.list(self.payload) == []
Пример #6
0
 def test_tc002052(self):
     contractType.modify("test_contract", name="买卖合同")
     assert contractType.list(self.payload) == []