diff options
author | Nadrieril Feneanar | 2019-08-03 22:21:40 +0200 |
---|---|---|
committer | GitHub | 2019-08-03 22:21:40 +0200 |
commit | ded09933a6783d1124b6c22ff0818fb525c3141d (patch) | |
tree | 5a4839e450b7fd09429742033c5b9732e453e2d1 /dhall/build.rs | |
parent | 30bc224b524031fbf64057516961831890bb749c (diff) | |
parent | 016893b00fcd916099e0349affc124fdd6275c67 (diff) |
Merge pull request #93 from Nadrieril/catchup-spec
Do some catch up on the spec
Diffstat (limited to 'dhall/build.rs')
-rw-r--r-- | dhall/build.rs | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/dhall/build.rs b/dhall/build.rs index 46bb3a4..3f09d47 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -35,11 +35,11 @@ fn dhall_files_in_dir<'a>( } fn make_test_module( - w: &mut impl Write, - mod_name: &str, - dir: &Path, - feature: &str, - mut exclude: impl FnMut(&str) -> bool, + w: &mut impl Write, // Where to output the generated code + mod_name: &str, // Name of the module, used in the output of `cargo test` + dir: &Path, // Directory containing the tests files + feature: &str, // Relevant variant of `dhall::tests::Feature` + mut exclude: impl FnMut(&str) -> bool, // Given a file name, whether to exclude it ) -> std::io::Result<()> { writeln!(w, "mod {} {{", mod_name)?; for (name, path) in dhall_files_in_dir(&dir.join("success/"), true) { @@ -67,6 +67,8 @@ fn make_test_module( } fn main() -> std::io::Result<()> { + // Tries to detect when the submodule gets updated; doesn't really work. + // To force regeneration of the test list, just `touch dhall-lang/.git` println!("cargo:rerun-if-changed=../dhall-lang/.git"); println!( "cargo:rerun-if-changed=../.git/modules/dhall-lang/refs/heads/master" @@ -129,6 +131,9 @@ fn main() -> std::io::Result<()> { path == "success/simple/integerToDouble" // Too slow || path == "success/remoteSystems" + // TODO: selection by expression + || path == "success/unit/RecordProjectionTypeEmpty" + || path == "success/unit/RecordProjectionTypeNonEmpty" }, )?; |