From 10326779b31146c23dbf9db5ca27e55a5db43f68 Mon Sep 17 00:00:00 2001 From: Anton-4 <17049058+Anton-4@users.noreply.github.com> Date: Wed, 21 Sep 2022 15:41:44 +0200 Subject: [PATCH] don't build swift on linux --- crates/cli/tests/cli_run.rs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/crates/cli/tests/cli_run.rs b/crates/cli/tests/cli_run.rs index 63da7bf0a7..478a0ae0f9 100644 --- a/crates/cli/tests/cli_run.rs +++ b/crates/cli/tests/cli_run.rs @@ -275,6 +275,7 @@ mod cli_run { ); } } + /// This macro does two things. /// /// First, it generates and runs a separate test for each of the given @@ -297,17 +298,20 @@ mod cli_run { let file_name = example_file(dir_name, example.filename); match example.executable_filename { - "form" | "hello-gui" | "breakout" | "ruby" | "swiftui" => { + "form" | "hello-gui" | "breakout" | "ruby" => { // Since these require things the build system often doesn't have // (e.g. GUIs open a window, Ruby needs ruby installed, WASM needs a browser) // we do `roc build` on them but don't run them. run_roc_on(&file_name, [CMD_BUILD, OPTIMIZE_FLAG], &[], None); return; } - "rocLovesSwift" => { + "swiftui" | "rocLovesSwift" => { if cfg!(not(target_os = "macos")) { eprintln!("WARNING: skipping testing example {} because it only works on MacOS.", example.filename); return; + } else { + run_roc_on(&file_name, [CMD_BUILD, OPTIMIZE_FLAG], &[], None); + return; } } "rocLovesWebAssembly" => {