title: python (django) regex limit result not working
body: <p>The spec is all characters except white-space and capitalized characters.</p>
  
  <p>Here is the regex validator on the model:</p>
  
  <pre><code>path = models.CharField(max_length=150, help_text="/blog/posts/...", unique=True, validators=[
          RegexValidator(regex='(^[a-z0-9-:!@#$%^&amp;*(){}\\?&lt;&gt;,.;\'"`~|/]+){1}', message="Lowercase with no whitespace allowed")
      ])
  </code></pre>
  
  <p>Here is the unit test:</p>
  
  <pre><code>def test_path_regex(self):
      with self.assertRaises(ValidationError):
          post = Post(title="bad regex", path="Super-2Test-2", slug="special")
          if post.full_clean():
              post.save()
  
      with self.assertRaises(ValidationError):
          post = Post(title="bad regex", path="super-2test 2", slug="special")
          if post.full_clean():
              post.save()
  
      self.assertEqual(Post.objects.filter(title="bad regex").count(), 0)
  </code></pre>
  
  <p>Result:</p>
  
  <pre><code>line 27, in test_path_regex
      post.save()
  AssertionError: ValidationError not raised
  
  FAILED (failures=1)
  </code></pre>
  
  <p>the reason for this seems to be that the <code>RegexValidator</code> is not flagging text if it can match part of the string and <code>{1}</code> is not helping. As you can see from this link: <a href="http://pythex.org/?regex=(%5E%5Ba-z0-9-%3A!%40%23%24%25%5E%26*()%7B%7D%5C%5C%3F%3C%3E%2C.%3B%5C%27%22%60~%7C%2F%5D%2B)%7B1%7D&amp;test_string=super-2test%202&amp;ignorecase=0&amp;multiline=0&amp;dotall=0&amp;verbose=0" rel="nofollow noreferrer">http://pythex.org/</a></p>
  
  <p>Please help.
  Thanks.</p>