oslo.policy/oslo_policy/tests
Colleen Murphy 99daead510 Modernize policy checker
Without this patch, the policy checker issues a 'failed' result when
checking a system-scoped sample token against a policy string like
"role:admin and system_scope:all", because the policy checker does not
understand the 'system_scope' attribute that is now in oslo.context[1]
and wasn't parsing the "system" scope object from the sample token.
Similarly, it fails on a string like "user_id:%(user_id)s" because it
never looked up the user_id from the sample token. This change updates
the policy checker to understand token contexts and policies like these
so that more of the policy defaults in keystone, and soon other
projects, will pass. This also adds a new system-scoped sample token to
check against.

[1] https://review.opendev.org/530509

Change-Id: I02fbbc99d28aa5c787133f530f6e968341107bf7
2019-10-10 08:38:14 -07:00
..
__init__.py exported from oslo-incubator by graduate.sh 2014-12-09 14:40:01 -03:00
base.py Move _capture_stdout to a common place 2018-08-07 19:49:55 +00:00
test_checks.py Modernize policy checker 2019-10-10 08:38:14 -07:00
test_external.py http/https check rules as stevedore extensions 2017-10-05 08:40:47 -04:00
test_fixtures.py External Policy hook should support SSL 2017-09-27 13:08:26 -04:00
test_generator.py Only alias when policy names change 2019-07-25 19:17:33 +00:00
test_opts.py Fix sample config value when set_defaults is used 2019-01-07 18:11:41 +00:00
test_parser.py Change assertTrue(isinstance()) by optimal assert 2016-10-08 09:46:47 +08:00
test_policy.py Add attribute to suppress deprecation warnings 2019-08-05 12:35:21 -07:00
test_shell.py Modernize policy checker 2019-10-10 08:38:14 -07:00
test_sphinxext.py Add unit tests on the sphinxext indent function 2019-07-22 11:46:09 +02:00
test_sphinxpolicygen.py make the sphinxpolicygen extension handle multiple input/output files 2018-04-30 10:11:21 -04:00
token_fixture.py Modernize policy checker 2019-10-10 08:38:14 -07:00