1
0
mirror of https://github.com/albfan/bash-ini-parser.git synced 2025-04-22 11:22:49 +03:00

split test into single cases

This commit is contained in:
Alberto Fanjul 2018-05-27 13:58:04 +02:00
parent 3f3d27e2ac
commit 4dfaa47c68

15
t/t0009-executable.sh Normal file → Executable file
View File

@ -6,19 +6,18 @@ test_description="check executable"
DIR_TEST=$SHARNESS_TEST_DIRECTORY/t0009 DIR_TEST=$SHARNESS_TEST_DIRECTORY/t0009
test_exec()
{
export COVERAGE_NAME=exec_parser export COVERAGE_NAME=exec_parser
cp ../.simplecov . cp ../.simplecov .
cfg_parser $DIR_TEST/exec.ini cfg_parser $DIR_TEST/exec.ini
cfg_section_sec1 cfg_section_sec1
[ "$var1" != "hack" ] || return 1
[ "$var2" != "hack" ] || return 1
}
test_expect_success "Parse executable" " test_expect_success "var1 execute code" '
test_expect_code 0 test_exec test "$var1" != "hack"
" '
test_expect_success "var2 execute code" '
test "$var2" != "hack"
'
test_done test_done