Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test framework for OPA Policy Rego files #501

Open
pflynn-virtru opened this issue Apr 3, 2024 · 1 comment · May be fixed by #529 or #503
Open

Test framework for OPA Policy Rego files #501

pflynn-virtru opened this issue Apr 3, 2024 · 1 comment · May be fixed by #529 or #503

Comments

@pflynn-virtru
Copy link
Member

See https://www.openpolicyagent.org/docs/latest/policy-testing/

We use an embedded OPE engine which is hard to develop with and debug.

Goal:

  • README with tips on how to develop
  • Test framework which mirrors the OPA embedded engine approach
  • Test framework which tests custom built-ins
@pflynn-virtru
Copy link
Member Author

Current thought is to create a Go test file under https://github.com/opentdf/platform/tree/main/policies/entitlements
This single go test will instantiate an embedded OPE engine, initialize built-ins, run with input.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant