Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CheckItem ¶
type CheckItem struct { InputPath string OutputPath string ExcpectedPath string Verdict ugrade.Verdict Err error }
CheckItem contains single testcase item with checking result.
type CheckSuite ¶
CheckSuite contains testcase suite checking result.
type Checker ¶
type Checker interface { CheckSuite( ctx context.Context, spec ugrade.JobSpec, tcSuite TCSuite, submissionExec ExecutionResult, ) (*CheckSuite, error) }
Checker check correctness of contestant output.
type CompilationResult ¶
type CompilationResult struct { // Usage contains information about memory and cpu usage when compiling. Usage ugrade.Usage // ExecDir contains path to generated executable directory. This path is relative to host filesystem ExecDir string // ExecName contains executable file name generated by compiler. Thus, the path to executable file // is `ExecDir`/`ExecName` ExecName string // RuntimeImage contains path to compressed sandbox image file that can be used to run the executable RuntimeImage string }
CompilationResult represent compilation result.
type Compiler ¶
type Compiler interface {
Compile(ctx context.Context, source ugrade.SourceCode) (*CompilationResult, error)
}
Compiler compile source code and provide `CompilationResult`.
type ExecutionItem ¶
ExecutionItem represent single execution of contestant submission.
type ExecutionResult ¶
type ExecutionResult struct { Dir string Items []ExecutionItem }
ExecutionResult represent execution of contestant submission given testcase suite.
type Executor ¶
type Executor interface {
Execute(ctx context.Context, spec ugrade.JobSpec, tcSuite TCSuite) (*ExecutionResult, error)
}
Executor execute submission given testcase suite.
type TCGenerator ¶
TCGenerator generate testcase suite
Click to show internal directories.
Click to hide internal directories.