Tests (#131)
* add smoke tests implemented with pytest * add sweep tests, wandb tests and mixed-precision tests * update requirements.txt * remove .autoenv.template file * update readme
This commit is contained in:
1 parent
5cc767a595
commit
e0293193f5
30 files changed
+572
-280
No files matched your search
@@ -0,0 +1,15 @@
|
||||
from typing import List
|
||||
|
||||
import pytest
|
||||
import sh
|
||||
|
||||
|
||||
def run_command(command: List[str]):
|
||||
"""Default method for executing shell commands with pytest."""
|
||||
msg = None
|
||||
try:
|
||||
sh.python(command)
|
||||
except sh.ErrorReturnCode as e:
|
||||
msg = e.stderr.decode()
|
||||
if msg:
|
||||
pytest.fail(msg=msg)
|
||||
Reference in new issue
Block a user