class TestReset: def setup(self): self.main = App() def teardown(self): self.main.base_quit() def test_reset(self): btn_clear = self.main.start().my().goto_cal().reset() assert btn_clear == "清空历史"
class TestLoan: def setup(self): self.main = App() def teardown(self): self.main.base_quit() def test_loan(self): contains = self.main.start().my().goto_cal().loan() assert contains == "首付比例"
class TestSalesList: def setup(self): self.main = App() def teardown(self): self.main.base_quit() def test_sales_list(self): type = self.main.start().my().more().goto_sales_ranking().sales_list() assert type == "国产/中大型SUV"
class TestPopularityList: def setup(self): self.main = App() def teardown(self): self.main.base_quit() def test_popularity_list(self): type = self.main.start().my().more().goto_sales_ranking( ).popularity_list() assert type == "进口/中大型SUV"
class TestCommentList: def setup(self): self.main = App() def teardown(self): self.main.base_quit() def test_comment_list(self): type = self.main.start().my().more().goto_sales_ranking().comment_list( ) assert type == "进口/中大型SUV"
class TestSwitchPosition: def setup(self): self.main = App() def teardown(self): self.main.base_quit() def test_switch_position(self): addr = self.main.start().my().more().goto_nearby_dealers( ).switch_position() assert "深圳" in addr
class TestFourStepCarSelection: def setup(self): self.main = App() def teardown(self): self.main.base_quit() def test_four_step_car_selection(self): ask_price_btn = self.main.start().my().goto_four_step_car_selection( ).four_steps() assert ask_price_btn == "获取底价"
class TestCompare: def setup(self): self.main = App() def teardown(self): self.main.base_quit() def test_compare(self): dealer_price = self.main.start().my().goto_model_comparison( ).start_compare() assert dealer_price == "经销商报价"
class TestNearbyDealers: def setup(self): self.main = App() def teardown(self): self.main.base_quit() def test_nearby_dealers(self): sales_title = self.main.start().my().more().goto_nearby_dealers( ).nearby_dealers() assert sales_title == "咨询销售顾问"
class TestEditAllDel: def setup(self): self.main = App() def teardown(self): self.main.base_quit() def test_edit_all_del(self): empty_info = self.main.start().my().goto_model_comparison( ).edit_all_del() return empty_info == "暂无车款信息!快去添加车型对比吧"
class TestMap: def setup(self): self.main = App() def teardown(self): self.main.base_quit() def test_map(self): addr = self.main.start().my().more().goto_nearby_dealers().map() # 模拟器 # assert addr == "泉州展览城-东门" # OPPO assert addr == "泉州展览城"
def setup(self): self.main = App()