def test_t(f_one):
a = f_one
print(f"a: {a}")
with testit.step("12", "12"):
print("Testing")
assert a == "1"
pass
`
При закомментированных декораторах warning'ов нет, при раскомичивании любого декоратора в консоли появляются warning'и:
\lib\site-packages\_pytest\python.py:199 PytestReturnNotNoneWarning('Expected None, but temp.py::test_t returned <function test_t at 0x00000275E1A40EE0>, which will be an error in a future version of pytest. Did you mean to useassertinstead ofreturn?')
`import testit import pytest @pytest.fixture def f_one(): return "1"
@testit.displayName("qw")
@testit.externalId("322")
@testit.labels("sdfsf")
def test_t(f_one): a = f_one print(f"a: {a}") with testit.step("12", "12"): print("Testing") assert a == "1" pass `
При закомментированных декораторах warning'ов нет, при раскомичивании любого декоратора в консоли появляются warning'и:
\lib\site-packages\_pytest\python.py:199 PytestReturnNotNoneWarning('Expected None, but temp.py::test_t returned <function test_t at 0x00000275E1A40EE0>, which will be an error in a future version of pytest. Did you mean to use
assertinstead of
return?')