def test_parameters_needles3(self): sys.argv = [ "App.py", "data.json", "2", "knife", "Potted Plan", "Other1", "Other2", "Other3" ] main() self.assertIn('STARTING AT ID', sys.stdout.getvalue())
def test_parameters_json1(self): sys.argv = [ "App.py", "", ] main() self.assertIn(self.message, sys.stdout.getvalue())
from App import main if __name__ == '__main__': main()
def test_parameters_start_node4(self): sys.argv = ["App.py", "data.json", "2", "", ""] main() self.assertIn(self.message, sys.stdout.getvalue())
def test_parameters_needles1(self): sys.argv = ["App.py", "data.json", "2"] main() self.assertIn(self.message, sys.stdout.getvalue())
def test_parameters_start_node3(self): sys.argv = ["App.py", "data.json", "", "knife", "Potted Plan"] main() self.assertIn(self.message, sys.stdout.getvalue())
def test_no_parameters(self): sys.argv = ["App.py"] main() self.assertIn(self.message, sys.stdout.getvalue())