fix: Fix source_script() test

This commit is contained in:
ge 2022-05-14 20:10:49 +03:00
parent 6bd28cd6ae
commit 7cff116df3

View File

@ -57,14 +57,14 @@ setup() {
assert_output --partial 'Error: Unsupported URI scheme: scp' assert_output --partial 'Error: Unsupported URI scheme: scp'
} }
@test "Set local target" { @test "Set __main_target" {
. source.sh . source.sh
source_script $DIR/files/basic.plan source_script $DIR/files/basic.plan
[ "$local_target" == 'file:/var/backup' ] [ "$__main_target" == 'file:/var/backup' ]
} }
@test "Set local target from multiple 'file' targets" { @test "Set __main_target from multiple 'file' targets" {
. source.sh . source.sh
source_script $DIR/files/multiple_file_targets.plan source_script $DIR/files/multiple_file_targets.plan
[ "$local_target" == 'file:///home/backups' ] [ "$__main_target" == 'file:///home/backups' ]
} }