Example #1
0
 def test_bad_loglevel(self):
     try:
         out, err, exit_code = run_pyff("--loglevel=TRACE")
     except ValueError as ex:
         assert ('TRACE' in str(ex))
Example #2
0
 def test_version(self):
     out, err, exit_code = run_pyff("--version")
     assert (pyffversion in out)
     assert (exit_code == 0)
Example #3
0
 def test_bad_arg(self):
     out, err, exit_code = run_pyff("--snartibartfast")
     assert (exit_code == 2)
     assert ('snartibartfast' in out)
Example #4
0
 def test_run_signer_logfile(self):
     out, err, exit_code = run_pyff("--loglevel=DEBUG", "--logfile=%s" % self.logfile, self.signer)
     assert (exit_code == 0)
Example #5
0
 def test_help(self):
     out, err, exit_code = run_pyff("--help")
     assert (pyffdoc in out)
     assert (exit_code == 0)
Example #6
0
 def test_run_signer(self):
     out, err, exit_code = run_pyff("--loglevel=DEBUG", self.signer)
     assert err
     assert (exit_code == 0)
Example #7
0
 def test_run_bad(self):
     out, err, exit_code = run_pyff("--loglevel=DEBUG", self.bad)
     assert 'Traceback' in err
     assert 'No pipe named snartibartifast is installed' in err
     assert (exit_code == 255)
Example #8
0
 def test_bad_arg(self):
     out, err, exit_code = run_pyff("--snartibartfast")
     assert (exit_code == 2)
     assert ('snartibartfast' in out)
Example #9
0
 def test_bad_loglevel(self):
     try:
         out, err, exit_code = run_pyff("--loglevel=TRACE")
     except ValueError, ex:
         assert ('TRACE' in str(ex))
Example #10
0
 def test_help(self):
     out, err, exit_code = run_pyff("--help")
     assert (pyffdoc in out)
     assert (exit_code == 0)
Example #11
0
 def test_version(self):
     out, err, exit_code = run_pyff("--version")
     assert (pyffversion in out)
     assert (exit_code == 0)
Example #12
0
 def test_run_signer_logfile(self):
     out, err, exit_code = run_pyff("--loglevel=DEBUG",
                                    "--logfile=%s" % self.logfile,
                                    self.signer)
     assert (not out)
     assert (exit_code == 0)
Example #13
0
 def test_run_bad(self):
     out, err, exit_code = run_pyff("--loglevel=DEBUG", self.bad)
     assert (not out)
     assert 'Traceback' in err
     assert 'No pipe named snartibartifast is installed' in err
     assert (exit_code == 255)
Example #14
0
 def test_run_signer(self):
     out, err, exit_code = run_pyff("--loglevel=DEBUG", self.signer)
     assert (not out)
     assert err
     assert (exit_code == 0)
Example #15
0
 def test_bad_arg(self):
     out, err, exit_code = run_pyff("--snartibartfast")
     assert exit_code == 2
     assert "snartibartfast" in out
Example #16
0
 def test_run_bad(self):
     out, err, exit_code = run_pyff("--loglevel=DEBUG", self.bad)
     assert not out
     assert "Traceback" in err
     assert "No pipe named snartibartifast is installed" in err
     assert exit_code == 255