'If a non-admin creates an app, an administrator should be able to set config
values for that app.'

@mock.patch(u'requests.post', mock_status_ok)
def test_admin_can_create_config_on_other_apps(self):

    user = User.objects.get(username=u'autotest2')
    token = Token.objects.get(user=user).key
    url = u'/v1/apps'
    response = self.client.post(url, HTTP_AUTHORIZATION=u'token    {}'.format(token))
    self.assertEqual(response.status_code, 201)
    app_id = response.data[u'id']
    url = u'/v1/apps/{app_id}/config'.format(**locals())
    body = {u'values': json.dumps({u'PORT': u'5000'})}
    response = self.client.post(url, json.dumps(body), content_type=u'application/json', HTTP_AUTHORIZATION=u'token    {}'.format(self.token))
    self.assertEqual(response.status_code, 201)
    self.assertIn(u'PORT', response.data[u'values'])
    return response
