1.装饰器,放在函数前面,跳过用例 @pytest.mark.skip(reason="no way of currently testing this") import pytest def test1(): print('操作1') print("-----------------------------------------------") @pytest.mark.skip(reason="no way of currently testing…
前言 背景介绍:做wap页面自动化的时候,把url地址直接输入到浏览器(chrome浏览器有手机wap模式)上测试,有个按钮死活点不到,用wap模式的触摸事件也无法解决,后来想用jquery去执行点击. 发现报$ is not defined. # coding:utf-8 # 作者:上海-悠悠 import time from selenium.webdriver.chrome.options import Options from selenium import webdriver from…