]> gitweb.factorcode.org Git - factor.git/blob - basis/command-line/command-line-tests.factor
Add absolute-path to normalize any new root path. E.G. permit ~user
[factor.git] / basis / command-line / command-line-tests.factor
1 USING: command-line namespaces tools.test ;
2
3 { f { "a" "b" "c" } } [
4     { "factor" "-run=test-voc" "a" "b" "c" } parse-command-line
5     script get command-line get
6 ] unit-test
7
8 { f { "-a" "b" "c" } } [
9     { "factor" "-run=test-voc" "-a" "b" "c" } parse-command-line
10     script get command-line get
11 ] unit-test
12
13 { f { "a" "-b" "c" } } [
14     { "factor" "-run=test-voc" "a" "-b" "c" } parse-command-line
15     script get command-line get
16 ] unit-test
17
18 { f { "a" "b" "-c" } } [
19     { "factor" "-run=test-voc" "a" "b" "-c" } parse-command-line
20     script get command-line get
21 ] unit-test
22
23 { "a" { "b" "c" } } [
24     { "factor" "a" "b" "c" } parse-command-line
25     script get command-line get
26 ] unit-test
27
28 { "a" { "b" "c" } } [
29     { "factor" "-foo" "a" "b" "c" } parse-command-line
30     script get command-line get
31 ] unit-test
32
33 { "a:b:c" } [ { "factor" "-roots=a:b:c" } parse-command-line
34     "roots" get-global
35 ] unit-test