test that rename fails with 409 if it would clobber

(test already passes, but it should still be tested)

closes #4600
This commit is contained in:
MinRK 2013-11-25 23:20:23 -08:00
parent 85dc6867f9
commit b82b4997e7

View File

@ -245,6 +245,10 @@ class APITest(NotebookTestBase):
self.assertIn('z.ipynb', nbnames)
self.assertNotIn('a.ipynb', nbnames)
def test_rename_existing(self):
with assert_http_error(409):
self.nb_api.rename('a.ipynb', 'foo', 'b.ipynb')
def test_save(self):
resp = self.nb_api.read('a.ipynb', 'foo')
nbcontent = json.loads(resp.text)['content']