mirror of
https://github.com/open-policy-agent/opa.git
synced 2026-08-12 19:32:48 -06:00
cmd+tester: Parameterized tests (#7366)
Adding the ability to parameterize Rego `test_*` rules, effectively declaring multiple "test cases" within the rule, which is then individually reported (grouped under their parent rule) when running `opa test`. Fixes: #2176 Signed-off-by: Johan Fylling <johan.dev@fylling.se>
This commit is contained in:
@@ -1617,6 +1617,20 @@
|
||||
"type": "function"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "internal.test_case",
|
||||
"decl": {
|
||||
"args": [
|
||||
{
|
||||
"dynamic": {
|
||||
"type": "any"
|
||||
},
|
||||
"type": "array"
|
||||
}
|
||||
],
|
||||
"type": "function"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "intersection",
|
||||
"decl": {
|
||||
|
||||
Reference in New Issue
Block a user