pytest- method name file name class name with operative Example

pytest test_class_01.py executable file name

pytest -v -s test_class_01.py executable file name

pytest -v test_class_01.py::TestClass execution class name

pytest -v test_class_01.py::TestClass::test_one execution method name

pytest -v -s test_mark.py -k test_add only execute this method

pytest -v -s test_mark.py -k "test_class and add" and the belt to perform this type of add

Guess you like

Origin www.cnblogs.com/QaStudy/p/11563953.html