1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-02 15:38:15 +00:00

add fileuuidmap to filecomment & del seahub signal

This commit is contained in:
zming
2017-09-15 16:15:10 +08:00
parent 60667e54a9
commit f2168d9602
11 changed files with 64 additions and 107 deletions

View File

@@ -44,3 +44,17 @@ class FileCommentsCountsTest(BaseTestCase):
if d.keys()[0] == 'test2.txt':
assert d['test2.txt'] == 1
def test_can_get_file(self):
FileComment.objects.add_by_file_path(repo_id=self.repo.id,
file_path=self.file2,
author=self.user.username,
comment='test comment on other file')
FileComment.objects.add_by_file_path(repo_id=self.repo.id,
file_path=self.file2,
author=self.user.username,
comment='test comment on other file123')
self.file_request= reverse('api2-file-comments-counts', args=[self.repo.id]) + '?p=' + self.file2
resp = self.client.get(self.file_request)
self.assertEqual(404, resp.status_code)