TestReport

scalation.modeling.autograd.TestReport
See theTestReport companion object
final class TestReport

A test report utility for recording and summarizing test results. Stores a collection of TestResult objects and provides support for timing tests, capturing failures, and printing formatted summary reports.

Attributes

Companion
object
Graph
Supertypes
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

def hasFailures: Boolean

Check whether any recorded tests have failed.

Check whether any recorded tests have failed.

Attributes

Returns

true if any test has status Failed, false otherwise

inline def record(name: String)(inline body: => Boolean): Boolean

Record and execute a test, capturing its execution time and status.

Record and execute a test, capturing its execution time and status.

Value parameters

body

the test code to execute (returns true on success)

name

the name of the test

Attributes

Returns

true if the test passed, false otherwise

def reset(): Unit

Clear all recorded test results.

Clear all recorded test results.

Attributes

def summary(title: String = ..., onlyFailures: Boolean = ...): Unit

Print a formatted summary of all recorded tests.

Print a formatted summary of all recorded tests.

Value parameters

onlyFailures

whether to print only failed tests (default false)

title

title of the test report (default "Test Report")

Attributes