Working state

This commit is contained in:
DarkFeather
2019-04-15 15:58:35 -05:00
parent 4310ab7323
commit 151648f44f
15 changed files with 147 additions and 53 deletions

View File

@@ -9,7 +9,7 @@ def CheckOutput(output):
def test_c():
print(os.getcwd())
fh = os.popen("make c &>/dev/null; ./helloworld", mode='r', buffering=-1)
fh = os.popen("make c &>/dev/null; ./HelloWorld", mode='r', buffering=-1)
output = fh.read()
retcode = fh.close()
assert retcode == None and CheckOutput(output)
@@ -23,42 +23,35 @@ def test_cs():
def test_java():
print(os.getcwd())
fh = os.popen("make java &>/dev/null; java helloworld", mode='r', buffering=-1)
fh = os.popen("make java &>/dev/null; java HelloWorld", mode='r', buffering=-1)
output = fh.read()
retcode = fh.close()
assert retcode == None and CheckOutput(output)
def test_bash():
print(os.getcwd())
fh = os.popen("bash ./helloworld.bash", mode='r', buffering=-1)
output = fh.read()
retcode = fh.close()
assert retcode == None and CheckOutput(output)
def test_bash():
print(os.getcwd())
fh = os.popen("bash ./helloworld.bash", mode='r', buffering=-1)
fh = os.popen("./HelloWorld.bash", mode='r', buffering=-1)
output = fh.read()
retcode = fh.close()
assert retcode == None and CheckOutput(output)
def test_perl():
print(os.getcwd())
fh = os.popen("perl ./helloworld.pl", mode='r', buffering=-1)
fh = os.popen("./HelloWorld.pl", mode='r', buffering=-1)
output = fh.read()
retcode = fh.close()
assert retcode == None and CheckOutput(output)
def test_php():
print(os.getcwd())
fh = os.popen("php ./helloworld.php", mode='r', buffering=-1)
fh = os.popen("php ./HelloWorld.php", mode='r', buffering=-1)
output = fh.read()
retcode = fh.close()
assert retcode == None and CheckOutput(output)
def test_python():
print(os.getcwd())
fh = os.popen("python3 ./helloworld.py", mode='r', buffering=-1)
fh = os.popen("./HelloWorld.py", mode='r', buffering=-1)
output = fh.read()
retcode = fh.close()
assert retcode == None and CheckOutput(output)