Limit scripts in path for tests
shellspec adds spec/support/bin to the path, so we can put scripts that should always be available here. Also don't source sxmo_common.sh in the helper, if scripts don't do it themselves we shouldn't do it for them in the tests. Signed-off-by: Anjandev Momi <anjan@momi.ca>
This commit is contained in:
@@ -1,6 +1,3 @@
|
||||
# shellcheck disable=SC2155
|
||||
export PATH="$PATH:$(pwd)/scripts/core"
|
||||
|
||||
# This file is to investigate whether sxmo_common.sh is loaded in tests
|
||||
|
||||
Describe 'sxmo_common.sh'
|
||||
|
@@ -1,4 +1,3 @@
|
||||
# shellcheck disable=SC2155
|
||||
# SPDX-License-Identifier: AGPL-3.0-only
|
||||
# Copyright 2022 Sxmo Contributors
|
||||
export PATH="$PATH:$(pwd)/scripts/core:$(pwd)/configs/default_hooks"
|
||||
|
@@ -7,10 +7,6 @@
|
||||
# so it is better to set them here.
|
||||
# set -eu
|
||||
|
||||
# Include common aliases such as find='busybox find' to avoid breaking
|
||||
# expected coreutils environment.
|
||||
. scripts/core/sxmo_common.sh
|
||||
|
||||
# This callback function will be invoked only once before loading specfiles.
|
||||
spec_helper_precheck() {
|
||||
# Available functions: info, warn, error, abort, setenv, unsetenv
|
||||
|
1
spec/support/bin/sxmo_common.sh
Symbolic link
1
spec/support/bin/sxmo_common.sh
Symbolic link
@@ -0,0 +1 @@
|
||||
../../../scripts/core/sxmo_common.sh
|
1
spec/support/bin/sxmo_hook_icons.sh
Symbolic link
1
spec/support/bin/sxmo_hook_icons.sh
Symbolic link
@@ -0,0 +1 @@
|
||||
../../../configs/default_hooks/sxmo_hook_icons.sh
|
Reference in New Issue
Block a user