Implement deterministic check APIs
This commit is contained in:
parent
fa1b42e678
commit
54984585e3
5 changed files with 448 additions and 4 deletions
|
|
@ -144,6 +144,11 @@ func LoadAndValidateFile(ctx context.Context, path string) (*Package, error) {
|
|||
return pkg, nil
|
||||
}
|
||||
|
||||
// Evaluate runs the package decision entrypoint for a normalized check request.
|
||||
func (p *Package) Evaluate(ctx context.Context, request api.CheckRequest) (api.DecisionExpectation, error) {
|
||||
return p.evaluateDecision(ctx, request)
|
||||
}
|
||||
|
||||
// Validate runs metadata, CARING, OPA parse/test, and fixture validation.
|
||||
func (p *Package) Validate(ctx context.Context) ValidationResult {
|
||||
result := ValidationResult{}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue