Commit 363fc462 by Scott Duckworth

test invalid key

parent 40d916cd
......@@ -105,6 +105,14 @@ class UserKeyCreationTestCase(BaseTestCase):
)
self.assertRaises(ValidationError, key.full_clean)
def test_invalid_key_fails(self):
key = UserKey(
user = self.user1,
name = 'name',
key = 'ssh-rsa invalid',
)
self.assertRaises(ValidationError, key.full_clean)
def test_key_with_options_fails(self):
key = UserKey(
user = self.user1,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment