Commit | Line | Data |
---|---|---|
1a3850a5 | 1 | #!./perl |
2 | ||
3 | BEGIN { | |
4 | chdir 't' if -d 't'; | |
5 | @INC = '../lib'; | |
6 | } | |
7 | ||
8 | print "1..3\n"; | |
9 | ||
10 | use Text::Tabs; | |
11 | ||
12 | $tabstop = 4; | |
13 | ||
14 | $s1 = "foo\tbar\tb\tb"; | |
15 | $s2 = expand $s1; | |
16 | $s3 = unexpand $s2; | |
17 | ||
18 | print "not " unless $s2 eq "foo bar b b"; | |
19 | print "ok 1\n"; | |
20 | ||
21 | print "not " unless $s3 eq "foo bar b\tb"; | |
22 | print "ok 2\n"; | |
23 | ||
24 | ||
25 | $tabstop = 8; | |
26 | ||
27 | print "not " unless unexpand(" foo") eq "\t\t foo"; | |
28 | print "ok 3\n"; |