|
13 | 13 | ArchivistDuplicateError, |
14 | 14 | ArchivistIllegalArgumentError, |
15 | 15 | ArchivistNotFoundError, |
| 16 | + ArchivistNotImplementedError, |
16 | 17 | ArchivistTooManyRequestsError, |
17 | 18 | ) |
18 | 19 |
|
@@ -129,27 +130,32 @@ def test_archivist_with_both_auth_and_cert(self): |
129 | 130 | with self.assertRaises(ArchivistIllegalArgumentError): |
130 | 131 | arch = Archivist("url", auth="authauthauth", cert="/path/to/file") |
131 | 132 |
|
132 | | - @mock.patch("archivist.archivist.os_path_isfile") |
133 | | - def test_archivist_with_nonexistent_cert(self, mock_isfile): |
| 133 | + # @mock.patch("archivist.archivist.os_path_isfile") |
| 134 | + # def test_archivist_with_nonexistent_cert(self, mock_isfile): |
| 135 | + def test_archivist_with_nonexistent_cert(self): |
134 | 136 | """ |
135 | 137 | Test archivist creation with nonexistent cert |
136 | 138 | """ |
137 | | - mock_isfile.return_value = False |
138 | | - with self.assertRaises(ArchivistNotFoundError): |
| 139 | + # mock_isfile.return_value = False |
| 140 | + # with self.assertRaises(ArchivistNotFoundError): |
| 141 | + with self.assertRaises(ArchivistNotImplementedError): |
139 | 142 | arch = Archivist("url", cert="/path/to/file") |
140 | 143 |
|
141 | | - @mock.patch("archivist.archivist.os_path_isfile") |
142 | | - def test_archivist_with_existent_cert(self, mock_isfile): |
| 144 | + # @mock.patch("archivist.archivist.os_path_isfile") |
| 145 | + # def test_archivist_with_existent_cert(self, mock_isfile): |
| 146 | + def test_archivist_with_existent_cert(self): |
143 | 147 | """ |
144 | | - Test archivist creation with cert |
| 148 | + Test archivist creation with cert - not currently implemented |
145 | 149 | """ |
146 | | - mock_isfile.return_value = True |
147 | | - arch = Archivist("url", cert="/path/to/file") |
148 | | - self.assertEqual( |
149 | | - arch.cert, |
150 | | - "/path/to/file", |
151 | | - msg="verify must be False", |
152 | | - ) |
| 150 | + with self.assertRaises(ArchivistNotImplementedError): |
| 151 | + arch = Archivist("url", cert="/path/to/file") |
| 152 | + # mock_isfile.return_value = True |
| 153 | + # arch = Archivist("url", cert="/path/to/file") |
| 154 | + # self.assertEqual( |
| 155 | + # arch.cert, |
| 156 | + # "/path/to/file", |
| 157 | + # msg="verify must be False", |
| 158 | + # ) |
153 | 159 |
|
154 | 160 |
|
155 | 161 | class TestArchivistMethods(TestCase): |
|
0 commit comments