Comment 1 for bug 1520383

Revision history for this message
Julian Edwards (julian-edwards) wrote : Re: Tests that need policy.json can never find it

Snippet from the server-side traceback:

  File "keystone/common/wsgi.py", line 329, in assert_admin
    self.policy_api.enforce(creds, 'admin_required', {})
  File "keystone/policy/backends/rules.py", line 77, in enforce
    enforce(credentials, action, target)
  File "keystone/policy/backends/rules.py", line 69, in enforce
    return _ENFORCER.enforce(action, target, credentials, **extra)
  File "/home/juledwar/mcopenstack/keystone/.tox/debug/local/lib/python2.7/site-packages/oslo_policy/policy.py", line 488, in enforce
    self.load_rules()
  File "/home/juledwar/mcopenstack/keystone/.tox/debug/local/lib/python2.7/site-packages/oslo_policy/policy.py", line 393, in load_rules
    self.policy_path = self._get_policy_path(self.policy_file)
  File "/home/juledwar/mcopenstack/keystone/.tox/debug/local/lib/python2.7/site-packages/oslo_policy/policy.py", line 461, in _get_policy_path
    raise cfg.ConfigFilesNotFoundError((path,))
ConfigFilesNotFoundError: Failed to find some config files: policy.json