33 lines
1.3 KiB
Plaintext
33 lines
1.3 KiB
Plaintext
#! @file main.sakura
|
|||
|
|
#! @author John Christman (sorakatadzuma@gmail.com)
|
||
|
|
#! @copyright Malunal Studios, LLC.
|
||
|
|
#! @license MIT
|
||
|
|
#!
|
||
|
|
#! Contains the `main` that runs this repository's unit tests, each in a copy of
|
||
|
|
#! the program of its own: those of finding libraries, in `libraries.sakura`,
|
||
|
|
#! and those of each of the compiler's libraries, in the folder of its name, as
|
||
|
|
#! `tests/analyzer/`. Each set is a program of its own, read from the root of
|
||
|
|
#! the repository, where `core` and `runtime` are, with the repositories of
|
||
|
|
#! `system` and the standard library beside it.
|
||
|
|
#!
|
||
|
|
#! `blossom test` runs them as `sakurac.tests` and `sakura.analyzer.tests` and
|
||
|
|
#! the rest, or, from the root of the repository:
|
||
|
|
#!
|
||
|
|
#! ```
|
||
|
|
#! sakurac run --lib std=../std --lib system=../system/system
|
||
|
|
#! --lib sakura::analyzer=analyzer tests/main.sakura tests/libraries.sakura
|
||
|
|
#! sakurac run --lib std=../std --lib system=../system/system
|
||
|
|
#! --lib sakura::analyzer=analyzer tests/main.sakura tests/analyzer/*.sakura
|
||
|
|
#! ```
|
||
|
|
#!
|
||
|
|
#! Each library's README gives the libraries its tests read.
|
||
|
|
#!
|
||
|
|
#! Add `-- --only TEXT` to run the tests whose name holds the text, and
|
||
|
|
#! `-- --here` to run them in one program, as a debugger wants.
|
||
|
|
|
||
|
|
import system;
|
||
|
|
import std::testing;
|
||
|
|
|
||
|
|
def main(args: span<strview>): void {
|
||
|
|
exit(tester::run(args));
|
||
|
|
}
|