diff --git a/mise.toml b/mise.toml index c4fe003f..52b6ddb4 100644 --- a/mise.toml +++ b/mise.toml @@ -26,3 +26,6 @@ fd = 'latest' [task_config] includes = ["scripts"] + +[tasks.test] +depends = ["dev:partitioned-test 1", "dev:partitioned-test 2"] diff --git a/scripts/dev/partitioned-test b/scripts/dev/partitioned-test new file mode 100755 index 00000000..55b13b49 --- /dev/null +++ b/scripts/dev/partitioned-test @@ -0,0 +1,13 @@ +#!/usr/bin/env bash + +#MISE description="Run project tests" +#USAGE arg "" help="The number of the partition" + +set -e + +source "$(git rev-parse --show-toplevel)/scripts/_helpers.sh" + +ensure_working_directory! + +# shellcheck disable=SC2154 +MIX_TEST_PARTITION="${usage_partition_number}" mix test --partitions 2 diff --git a/scripts/dev/test b/scripts/dev/test deleted file mode 100755 index 87ec055c..00000000 --- a/scripts/dev/test +++ /dev/null @@ -1,11 +0,0 @@ -#!/usr/bin/env bash - -#MISE description="Run project tests" - -set -e - -source "$(git rev-parse --show-toplevel)/scripts/_helpers.sh" - -ensure_working_directory! - -mix test