

def test_get_no_entity_key_string_and_no_entities_in_namespace(self):
    request = webapp2.Request.blank('/datastore/edit?kind=Kind1&namespace=cat&next=http://next/')
    response = webapp2.Response()
    handler = datastore_viewer.DatastoreEditRequestHandler(request, response)
    self.mox.ReplayAll()
    handler.get()
    self.mox.VerifyAll()
    self.assertEqual(302, response.status_int)
    self.assertRegexpMatches(response.location, '/datastore\\?kind=Kind1&message=Cannot+.*&namespace=cat')

dataset/ETHPy150Open GoogleCloudPlatform/python-compat-runtime/appengine-compat/exported_appengine_sdk/google/appengine/tools/devappserver2/admin/datastore_viewer_test.py DatastoreEditRequestHandlerTest.test_get_no_entity_key_string_and_no_entities_in_namespace/original