mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-29 06:44:46 +00:00
Add some documentation to cli_run test
This commit is contained in:
parent
aef758b1c9
commit
6cd445d731
1 changed files with 11 additions and 0 deletions
|
@ -108,6 +108,17 @@ mod cli_run {
|
||||||
assert!(out.status.success());
|
assert!(out.status.success());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// This macro does two things.
|
||||||
|
///
|
||||||
|
/// First, it generates and runs a separate test for each of the given
|
||||||
|
/// Example expressions. Each of these should test a particular .roc file
|
||||||
|
/// in the examples/ directory.
|
||||||
|
///
|
||||||
|
/// Second, it generates an extra test which recursively traverses the
|
||||||
|
/// examples/ directory and verifies that each of the .roc files in there
|
||||||
|
/// has had a corresponding test generated in the previous step. This test
|
||||||
|
/// will fail if we ever add a new .roc file to examples/ and forget to
|
||||||
|
/// add a test for it here!
|
||||||
macro_rules! examples {
|
macro_rules! examples {
|
||||||
($($name:expr => [$($test_name: ident: $examples:expr,)*],)*) => {
|
($($name:expr => [$($test_name: ident: $examples:expr,)*],)*) => {
|
||||||
$(
|
$(
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue