예제 #1
0
 def test_delete_with_id_nonexistent(self):
     system = LogSearchSystem()
     system.save()
     nonexistent_id = system.id
     system.delete()
     response = self._delete(nonexistent_id)
     self.assertEquals(response.status_code, httplib.NOT_FOUND)
예제 #2
0
 def test_get_with_id_nonexsitent(self):
     system = LogSearchSystem(type='groonga',
                              base_url='http://search.example.com/#!/tables/Logs/search')
     system.save()
     id = system.id
     system.delete()
     response = self._get(id)
     self.assertEquals(response.status_code, httplib.NOT_FOUND)
예제 #3
0
 def test_put_with_id_nonexistent(self):
     system = LogSearchSystem(type='groonga',
                              base_url='http://search.example.com/#!/tables/Logs/search')
     system.save()
     nonexistent_id = system.id
     system.delete()
     record = {
         'type': 'other',
         'base_url': 'http://search.example.net/',
     }
     response = self._put(nonexistent_id, record)
     self.assertEquals(response.status_code, httplib.NOT_FOUND)