File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -97,12 +97,13 @@ rm -rf dirExampleE
9797rm -rf dirExampleA
9898rm -rf dirExampleD
9999
100+ # countdown, echo, form... all require user input or special setup
101+ ignore_list=(" stdin-basic.roc" " stdin-pipe.roc" " command-line-args.roc" " http.roc" " env-var.roc" " bytes-stdin-stdout.roc" " error-handling.roc" " tcp-client.roc" " tcp.roc" " terminal-app-snake.roc" )
102+
100103# roc dev (some expects only run with `roc dev`)
101104for roc_file in $EXAMPLES_DIR * .roc; do
102105 base_file=$( basename " $roc_file " )
103106
104- # countdown, echo, form... all require user input or special setup
105- ignore_list=(" stdin-basic.roc" " stdin-pipe.roc" " command-line-args.roc" " http.roc" " env-var.roc" " bytes-stdin-stdout.roc" " error-handling.roc" " tcp-client.roc" " terminal-app-snake.roc" )
106107
107108 # check if base_file matches something from ignore_list
108109 for file in " ${ignore_list[@]} " ; do
@@ -130,9 +131,17 @@ for roc_file in $EXAMPLES_DIR*.roc; do
130131 $ROC dev $roc_file $ROC_BUILD_FLAGS
131132 fi
132133done
134+
133135for roc_file in $TESTS_DIR * .roc; do
134136 base_file=$( basename " $roc_file " )
135137
138+ # check if base_file matches something from ignore_list
139+ for file in " ${ignore_list[@]} " ; do
140+ if [ " $base_file " == " $file " ]; then
141+ continue 2 # continue the outer loop if a match is found
142+ fi
143+ done
144+
136145 if [ " $base_file " == " sqlite.roc" ]; then
137146 DB_PATH=${TESTS_DIR} test.db $ROC dev $roc_file $ROC_BUILD_FLAGS
138147 else
Original file line number Diff line number Diff line change 3030 rust =
3131 pkgs . rust-bin . fromRustupToolchainFile "${ toString ./rust-toolchain.toml } " ;
3232
33+ aliases = ''
34+ alias testcmd='export ROC=roc && export EXAMPLES_DIR=./examples/ && ./ci/all_tests.sh'
35+ '' ;
36+
3337 linuxInputs = with pkgs ;
3438 lib . optionals stdenv . isLinux [
3539 valgrind
6468 # for crti.o, crtn.o, and Scrt1.o
6569 NIX_GLIBC_PATH =
6670 if pkgs . stdenv . isLinux then "${ pkgs . glibc . out } /lib" else "" ;
71+
72+ shellHook = ''
73+ ${ aliases }
74+ '' ;
6775 } ;
6876
6977 formatter = pkgs . nixpkgs-fmt ;
You can’t perform that action at this time.
0 commit comments