diff options
author | Jonathan Lange <jml@canonical.com> | 2012-07-22 10:10:31 +0100 |
---|---|---|
committer | Jonathan Lange <jml@canonical.com> | 2012-07-22 10:10:31 +0100 |
commit | a8feb9a9a8f67da0de9992f02251ba841b0384cd (patch) | |
tree | 08ee75b1374cd8545ac5ebf6e2fcf628ccc7c7b0 | |
parent | 15596b4a395c1aab8753b34b96b8d3f47094c498 (diff) | |
download | fixtures-a8feb9a9a8f67da0de9992f02251ba841b0384cd.tar.gz |
Rename NoHasattr to HasNoAttribute
-rw-r--r-- | lib/fixtures/tests/_fixtures/test_filetree.py | 4 | ||||
-rw-r--r-- | lib/fixtures/tests/_fixtures/test_tempdir.py | 4 | ||||
-rw-r--r-- | lib/fixtures/tests/_fixtures/test_temphomedir.py | 4 | ||||
-rw-r--r-- | lib/fixtures/tests/helpers.py | 4 |
4 files changed, 8 insertions, 8 deletions
diff --git a/lib/fixtures/tests/_fixtures/test_filetree.py b/lib/fixtures/tests/_fixtures/test_filetree.py index 4da1b89..45d6b75 100644 --- a/lib/fixtures/tests/_fixtures/test_filetree.py +++ b/lib/fixtures/tests/_fixtures/test_filetree.py @@ -32,7 +32,7 @@ from fixtures._fixtures.filetree import ( normalize_entry, normalize_shape, ) -from fixtures.tests.helpers import NotHasattr +from fixtures.tests.helpers import HasNoAttribute class TestFileTree(TestCase): @@ -40,7 +40,7 @@ class TestFileTree(TestCase): def test_no_path_at_start(self): # FileTree fixture doesn't create a path at the beginning. fixture = FileTree([]) - self.assertThat(fixture, NotHasattr('path')) + self.assertThat(fixture, HasNoAttribute('path')) def test_creates_directory(self): # It creates a temporary directory once set up. That directory is diff --git a/lib/fixtures/tests/_fixtures/test_tempdir.py b/lib/fixtures/tests/_fixtures/test_tempdir.py index 5fd5a46..5cda9a7 100644 --- a/lib/fixtures/tests/_fixtures/test_tempdir.py +++ b/lib/fixtures/tests/_fixtures/test_tempdir.py @@ -23,14 +23,14 @@ from fixtures import ( NestedTempfile, TempDir, ) -from fixtures.tests.helpers import NotHasattr +from fixtures.tests.helpers import HasNoAttribute class TestTempDir(testtools.TestCase): def test_basic(self): fixture = TempDir() - self.assertThat(fixture, NotHasattr('path')) + self.assertThat(fixture, HasNoAttribute('path')) fixture.setUp() try: path = fixture.path diff --git a/lib/fixtures/tests/_fixtures/test_temphomedir.py b/lib/fixtures/tests/_fixtures/test_temphomedir.py index 5e0db9a..028ebbe 100644 --- a/lib/fixtures/tests/_fixtures/test_temphomedir.py +++ b/lib/fixtures/tests/_fixtures/test_temphomedir.py @@ -22,14 +22,14 @@ from fixtures import ( TempDir, TempHomeDir, ) -from fixtures.tests.helpers import NotHasattr +from fixtures.tests.helpers import HasNoAttribute class TestTempDir(testtools.TestCase): def test_basic(self): fixture = TempHomeDir() - self.assertThat(fixture, NotHasattr('path')) + self.assertThat(fixture, HasNoAttribute('path')) fixture.setUp() try: path = fixture.path diff --git a/lib/fixtures/tests/helpers.py b/lib/fixtures/tests/helpers.py index 680d396..6ae07cc 100644 --- a/lib/fixtures/tests/helpers.py +++ b/lib/fixtures/tests/helpers.py @@ -36,14 +36,14 @@ class LoggingFixture(fixtures.Fixture): self.calls.append('reset' + self.suffix) -class NotHasattr(object): +class HasNoAttribute(object): """For asserting that an object does not have a particular attribute.""" def __init__(self, attr_name): self._attr_name = attr_name def __str__(self): - return 'NotHasattr(%s)' % (self._attr_name,) + return 'HasNoAttribute(%s)' % (self._attr_name,) def match(self, obj): sentinel = object() |