'Try uploading a layer and verify that the user can administrate
his own layer despite not being a site administrator.'

def test_layer_upload(self):

    self.client.login(username='norman', password='norman')
    norman = get_user_model().objects.get(username='norman')
    saved_layer = file_upload(os.path.join(gisdata.VECTOR_DATA, 'san_andres_y_providencia_poi.shp'), name='san_andres_y_providencia_poi_by_norman', user=norman, overwrite=True)
    saved_layer.set_default_permissions()
    url = reverse('layer_metadata', args=[saved_layer.service_typename])
    resp = self.client.get(url)
    self.assertEquals(resp.status_code, 200)
