Skip to content
This repository was archived by the owner on Jan 30, 2023. It is now read-only.

Commit 719e442

Browse files
committed
Run pytest as part of sage -t
1 parent 5fd49b7 commit 719e442

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

src/bin/sage-runtests

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,4 +181,13 @@ if __name__ == "__main__":
181181
DC = DocTestController(options, args)
182182
err = DC.run()
183183

184-
sys.exit(err)
184+
import pytest
185+
pytest_options = []
186+
if options.verbose:
187+
pytest_options.append("-v")
188+
exit_code_pytest = pytest.main(pytest_options + args)
189+
190+
if err == 0:
191+
sys.exit(exit_code_pytest)
192+
else:
193+
sys.exit(err)

0 commit comments

Comments
 (0)