Exemplo n.º 1
0
 def test_wrong_type(self):
     """
     Passing anything else than a boolean raises TypeError.
     """
     with pytest.raises(TypeError) as e:
         _config.set_run_validators("False")
     assert "'run' must be bool." == e.value.args[0]
Exemplo n.º 2
0
 def test_wrong_type(self):
     """
     Passing anything else than a boolean raises TypeError.
     """
     with pytest.raises(TypeError) as e:
         _config.set_run_validators("False")
     assert "'run' must be bool." == e.value.args[0]
Exemplo n.º 3
0
 def test_set_run_validators(self):
     """
     Sets `_run_validators`.
     """
     _config.set_run_validators(False)
     assert False is _config._run_validators
     _config.set_run_validators(True)
     assert True is _config._run_validators
Exemplo n.º 4
0
 def test_set_run_validators(self):
     """
     Sets `_run_validators`.
     """
     _config.set_run_validators(False)
     assert False is _config._run_validators
     _config.set_run_validators(True)
     assert True is _config._run_validators