摘要:
一、pytest的运行方式 # file_name: test_add.py import pytest # 导入pytest包 def test_add01(): # test开头的测试函数 print(" >>> test_add01") assert 1 # 断言成功 def test_add 阅读全文
摘要:
在学习pytest之前一直使用的是unittest,一直听说pytest相比于unittest更加灵活,年底了终于有时间学习一下pytest了! 一、pytest的安装 pip install pytest 二、验证pytest是否安装成功 pytest --version 出现以上内容表示pyte 阅读全文