Major overhaul getting started
This commit is contained in:
BIN
tests/__pycache__/test_unit.cpython-37-PYTEST.pyc
Normal file
BIN
tests/__pycache__/test_unit.cpython-37-PYTEST.pyc
Normal file
Binary file not shown.
15
tests/test_unit.py
Normal file
15
tests/test_unit.py
Normal file
@@ -0,0 +1,15 @@
|
||||
import os
|
||||
import re
|
||||
import shutil
|
||||
|
||||
def checkOutput(output):
|
||||
for line in output.split('\n'):
|
||||
if line == 'Hello world!': return True
|
||||
return False
|
||||
|
||||
def test_c():
|
||||
print(os.getcwd())
|
||||
fh = os.popen("./helloworld", mode='r', buffering=-1)
|
||||
output = fh.read()
|
||||
retcode = fh.close()
|
||||
assert retcode == None and checkOutput(output)
|
Reference in New Issue
Block a user