diff options
author | ReemMahmoud <rfawzy.ext@orange.com> | 2018-01-04 12:32:51 +0200 |
---|---|---|
committer | ReemMahmoud <rfawzy.ext@orange.com> | 2018-01-04 12:32:51 +0200 |
commit | 9165dfcf59b1325f317e8a412e5f775855354300 (patch) | |
tree | 53c9b8cba3f0587925bee82ccfcfdf540ff9168d /python_moondb/tests/unit_python/policies/mock_data.py | |
parent | 0f88d8acc6d55a2274376c949e3ad3f4fc14dac7 (diff) |
Add more moon-db tests
Change-Id: I9c0f08580528a6411420fe3d5e41ebbc18280cd2
Signed-off-by: ReemMahmoud <rfawzy.ext@orange.com>
Diffstat (limited to 'python_moondb/tests/unit_python/policies/mock_data.py')
-rw-r--r-- | python_moondb/tests/unit_python/policies/mock_data.py | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/python_moondb/tests/unit_python/policies/mock_data.py b/python_moondb/tests/unit_python/policies/mock_data.py index b2642979..23eeef64 100644 --- a/python_moondb/tests/unit_python/policies/mock_data.py +++ b/python_moondb/tests/unit_python/policies/mock_data.py @@ -30,6 +30,16 @@ def create_policy(model_id): return value +def create_pdp(pdp_ids): + value = { + "name": "test_pdp", + "security_pipeline": pdp_ids, + "keystone_project_id": "keystone_project_id1", + "description": "...", + } + return value + + def get_policy_id(): import policies.test_policies as test_policies import models.test_models as test_models @@ -39,7 +49,7 @@ def get_policy_id(): model = test_models.add_model(value=create_model(meta_rule_id)) model_id = list(model.keys())[0] value = create_policy(model_id) - policy = test_policies.add_policies(value) + policy = test_policies.add_policies(value=value) assert policy policy_id = list(policy.keys())[0] return policy_id |