Documentation
¶
Overview ¶
Package testacceptance composes actual, operator-approved experimental browser observations. Unknown validity remains unknown.
Index ¶
- Constants
- func Decode(data []byte, out any) error
- func Digest(r Request) string
- func Hash(data []byte) string
- func SafeEnvironment() []string
- func Validate(r Request) error
- func WorkerEnvironmentSafe() bool
- type Assessment
- type Cleanup
- type Command
- type Control
- type File
- type FreshnessOptions
- type Job
- type OrderEvidence
- type RepeatSummary
- type Report
- type Repository
- type Request
- type Row
- type Run
- type Test
- type WorkerResult
Constants ¶
const FreshRequestSchema = "corvint-new-e2e-request/1"
const FreshSchema = "corvint-new-e2e-assessment/1"
const InputLimit = 4 << 20
const IsolationRepeats = 2
IsolationRepeats is the fixed number of single-test runs for each test whose repeats disagree. It is not caller-selectable.
const ReportLimit = 16 << 20
const RequestSchema = "corvint-new-e2e-request/0"
const Schema = "corvint-new-e2e-assessment/0"
Variables ¶
This section is empty.
Functions ¶
func SafeEnvironment ¶
func SafeEnvironment() []string
SafeEnvironment is a fixed local execution environment. Author/request keys cannot opt credentials into it. Browser caches use the trusted host default.
func WorkerEnvironmentSafe ¶
func WorkerEnvironmentSafe() bool
WorkerEnvironmentSafe rejects a public direct worker invocation before any author/server code can observe inherited credentials or runtime injection.
Types ¶
type Assessment ¶
type Assessment struct {
ID string `json:"id"`
Verdict string `json:"verdict"`
Reasons []string `json:"reasons"`
Validity testvalidity.Projection `json:"validity"`
Repeats RepeatSummary `json:"repeats"`
Cleanup string `json:"cleanup"`
Order OrderEvidence `json:"order"`
}
type Control ¶
type Control struct {
Evidence *behaviorfalsify.EvidenceReceipt `json:"evidence,omitempty"`
ID string `json:"id"`
PlanDigest string `json:"plan_digest,omitempty"`
ReceiptDigest string `json:"receipt_digest,omitempty"`
Status string `json:"status"`
Unsupported []string `json:"unsupported"`
Cleanup Cleanup `json:"cleanup"`
}
type FreshnessOptions ¶
type FreshnessOptions struct {
Provider jstestprovider.FreshnessConfig `json:"provider"`
Attestation Command `json:"attestation"`
AttestationConfiguration File `json:"attestation_configuration"`
}
type Job ¶
type Job struct {
Approved string `json:"approved"`
Request Request `json:"request"`
Kind string `json:"kind"`
Files []string `json:"files,omitempty"`
TestIndex int `json:"test_index"`
}
Job is private to the self-worker protocol; it cannot supply observations.
type OrderEvidence ¶
type OrderEvidence struct {
Status string `json:"status"`
RequestedFileOrder string `json:"requested_file_order"`
OriginalState string `json:"original_state"`
ReversedState string `json:"reversed_state"`
IsolatedStates []string `json:"isolated_states"`
}
OrderEvidence attaches the order-dependence probes to the test they concern. Requested file filters and isolation runs are requests, not an observed schedule.
type RepeatSummary ¶
type RepeatSummary struct {
Passed int `json:"passed"`
Failed int `json:"failed"`
Other int `json:"other"`
MinDurationMS *float64 `json:"min_duration_ms,omitempty"`
MaxDurationMS *float64 `json:"max_duration_ms,omitempty"`
}
RepeatSummary counts actual zero-retry repeat rows for one declared test. Durations are present only when at least one row was observed.
type Report ¶
type Report struct {
Verdict string `json:"verdict"`
Reasons []string `json:"reasons"`
Schema string `json:"schema"`
RequestDigest string `json:"request_digest"`
Product Repository `json:"product"`
TestRepository Repository `json:"test_repository"`
Environment string `json:"environment"`
Build string `json:"build"`
ExecutableSHA256 string `json:"executable_sha256"`
Runs []Run `json:"runs"`
Controls []Control `json:"controls"`
Assessments []Assessment `json:"assessments"`
Unknowns []string `json:"unknowns"`
Body string `json:"body"`
}
type Repository ¶
type Request ¶
type Request struct {
Freshness *FreshnessOptions `json:"freshness,omitempty"`
Schema string `json:"schema"`
Product Repository `json:"product"`
TestRepository Repository `json:"test_repository"`
Inputs []File `json:"inputs"`
Tests []Test `json:"tests"`
Config string `json:"config"`
Package string `json:"package"`
Lockfile string `json:"lockfile"`
Runner Command `json:"runner"`
Server Command `json:"server"`
ReadyURL string `json:"ready_url"`
AppBuildDir string `json:"app_build_dir"`
RunnerVersion string `json:"runner_version"`
Environment string `json:"environment"`
Repeat int `json:"repeat"`
TimeoutSeconds int `json:"timeout_seconds"`
}
type Row ¶
type Row struct {
ID string `json:"id"`
ObservedID string `json:"observed_id,omitempty"`
State jstestprovider.ExecutionState `json:"state"`
DurationMS float64 `json:"duration_ms"`
Retries int `json:"retries"`
Attempts int `json:"attempts"`
Validity testvalidity.Projection `json:"validity"`
IdentityUnknown []string `json:"identity_unknown"`
}
type Run ¶
type Run struct {
NativeReceipt []byte `json:"native_receipt,omitempty"`
Kind string `json:"kind"`
Ordinal int `json:"ordinal"`
TestID string `json:"test_id,omitempty"`
RequestedFiles []string `json:"requested_files"`
ObservedSchedule *jstestprovider.ExecutionSchedule `json:"observed_schedule,omitempty"`
ReceiptSHA256 string `json:"receipt_sha256,omitempty"`
Rows []Row `json:"rows"`
Reasons []string `json:"reasons"`
Cleanup Cleanup `json:"cleanup"`
NodeVersion string `json:"node_version,omitempty"`
}
type Test ¶
type Test struct {
ID string `json:"id"`
File string `json:"file"`
Line int `json:"line"`
Title string `json:"title"`
Project string `json:"project"`
ControlCommand *Command `json:"control_command,omitempty"`
Control *behaviorfalsify.Plan `json:"control,omitempty"`
Tool *behaviorfalsify.ToolIdentity `json:"tool,omitempty"`
}