]> git.notmuchmail.org Git - notmuch/blob - test/T410-argument-parsing.sh
test: add boolean argument to arg-test
[notmuch] / test / T410-argument-parsing.sh
1 #!/usr/bin/env bash
2 test_description="argument parsing"
3 . ./test-lib.sh || exit 1
4
5 test_begin_subtest "sanity check"
6 $TEST_DIRECTORY/arg-test  pos1  --keyword=one --boolean --string=foo pos2 --int=7 --flag=one --flag=three > OUTPUT
7 cat <<EOF > EXPECTED
8 boolean 1
9 keyword 1
10 flags 5
11 int 7
12 string foo
13 positional arg 1 pos1
14 positional arg 2 pos2
15 EOF
16 test_expect_equal_file EXPECTED OUTPUT
17
18 test_done