@pytest.mark.parametrize("first,second", [(3,1), (-1,0), (1.5,1.0)]) deftest_values(first, second): assert(first > second) 測試結果如下: === test session starts === platform win32 -- Python 3.6.1, pytest-5.3.1, py-1.8.0, pluggy-0.13.1 rootdir: C:\Users\pythoncat\Pychar...
www.dbjr.com.cn/article/1760...htm 2025-5-24