def test_error(self): s = R.Stitch('') assert s.error == 'continue' s.error = 'raise' assert s.error == 'raise' with pytest.raises(TraitError): s.error = 'foo'