Documentation
¶
Overview ¶
Package fullverification discovers the project-wide build and test entrypoints that form the session-end machine verification floor.
Index ¶
Constants ¶
const ( DeclaredBuildSource = "--verify-build" DeclaredTestSource = "--verify-test" )
The sources a declared entrypoint carries, spelled as the flags a person typed, so every line that reports the command says where it came from.
Variables ¶
This section is empty.
Functions ¶
func ActivationPreamble ¶
ActivationPreamble is the shell lines that put the virtual environment for a command run in workdir first on PATH, the way its activate script does, and "" when there is none (ProjectVenv).
func ProjectVenv ¶
ProjectVenv is the Python virtual environment for a command run in workdir (relative to workspace, "" for the workspace itself): one in workdir, else one at the top of the workspace. A folder is one when it holds pyvenv.cfg and bin/python, a link to the interpreter it was made from, followed. "" when there is none.
Types ¶
type Declared ¶
Declared is the build and test commands a person named on the command line. An empty field leaves that kind to discovery.
type Entrypoint ¶
type Entrypoint struct {
Kind EntrypointKind `json:"kind"`
Command string `json:"command"`
Workdir string `json:"workdir,omitempty"`
Source string `json:"source"`
}
func (Entrypoint) IsDeclared ¶
func (entrypoint Entrypoint) IsDeclared() bool
IsDeclared reports whether an entrypoint came from the command line rather than from discovery.
type EntrypointKind ¶
type EntrypointKind string
const ( KindBuild EntrypointKind = "build" KindTest EntrypointKind = "test" )
type Plan ¶
type Plan struct {
Entrypoints []Entrypoint `json:"entrypoints"`
// BuildExpected reports whether this project is required to have a
// build/typecheck step. True for any accountable workspace — including one
// whose ecosystem we do not recognize — so the gate stays fail-closed; a
// plain Python package is the one case we can positively identify as
// having nothing to compile.
BuildExpected bool `json:"buildExpected"`
// TestExpected reports whether this project is required to have a test
// step. True for any accountable workspace: unlike a build, no ecosystem
// is exempt from having tests. Both flags are false only for a workspace
// that is not accountable at all (see accountableWorkspace).
TestExpected bool `json:"testExpected"`
}