Skip to content
Snippets Groups Projects
Commit 60d6bb05 authored by dilawar's avatar dilawar :ant:
Browse files

feat: Added a cli test

parent 33eeb678
No related branches found
No related tags found
1 merge request!2version 0.2.0
Pipeline #3730 failed with stages
in 1 minute and 53 seconds
import sys
import subprocess
def run_command(cmd: str, args: str):
cmd = f"{sys.executable} -m bitia {cmd} {args}"
print(f"Executing `{cmd}`")
return subprocess.check_output(cmd)
def test_cli_sanity():
output = run_command("run", '"ls -ltr /"')
print(output.decode().rstrip())
assert len(output) > 20, "Too little output"
if __name__ == "__main__":
test_cli_sanity()
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment