diff --git a/misc/entity_state_test_data.py b/misc/entity_state_test_data.py index ad4d531173002202ca328879725d63ab40853c60..ff06452cb33045e876e1f17a94862737e77a8207 100755 --- a/misc/entity_state_test_data.py +++ b/misc/entity_state_test_data.py @@ -15,7 +15,7 @@ def teardown(): def setup_users(): for role in ["publisher", "normal", "external"]: try: - db.administration._delete_user(name=role + "_user") + db.administration._delete_user(name=role+"_user") except BaseException: pass for role in ["publisher", "normal", "external"]: @@ -98,6 +98,7 @@ def setup_state_model(): unpublished_state.acl = unpublished_acl unpublished_state.insert() + review_acl = db.ACL() review_acl.grant(role="publisher", permission="*") review_acl.grant(role="normal", permission="RETRIEVE:ENTITY") @@ -111,6 +112,7 @@ def setup_state_model(): review_state.acl = db.State.create_state_acl(review_acl) review_state.insert() + published_acl = db.ACL() published_state = db.Record( @@ -153,8 +155,7 @@ def setup_state_model(): "Transition").add_property("from", "under review").add_property("to", "unpublished").insert() # 1->1 - db.Record("Edit", - description="Edit this entity. The changes are not publicly available until this entity will have been reviewed and published.").add_parent( + db.Record("Edit", description="Edit this entity. The changes are not publicly available until this entity will have been reviewed and published.").add_parent( "Transition").add_property( "from", "unpublished").add_property(