summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@tavianator.com>2017-01-14 16:38:08 -0500
committerTavian Barnes <tavianator@tavianator.com>2017-02-05 19:02:25 -0500
commita6f94c132c425bbab543e98fcd19f4ff7519d1b7 (patch)
tree215135837c0335946b70593877ec5411ba8e6c17 /tests
parent9f1863d45fe596e258596a4b4cc9a4064bcb11d3 (diff)
downloadbfs-a6f94c132c425bbab543e98fcd19f4ff7519d1b7.tar.xz
Implement -printf/-fprintf
Based on a patch by Fangrui Song <i@maskray.me>. Closes #16.
Diffstat (limited to 'tests')
-rw-r--r--tests/test_0130.out19
-rw-r--r--tests/test_0131.out1
-rw-r--r--tests/test_0132.out1
-rw-r--r--tests/test_0133.out19
-rw-r--r--tests/test_0134.out19
-rw-r--r--tests/test_0135.out19
-rw-r--r--tests/test_0136.out10
-rw-r--r--tests/test_0137.out1
8 files changed, 89 insertions, 0 deletions
diff --git a/tests/test_0130.out b/tests/test_0130.out
new file mode 100644
index 0000000..801ddbb
--- /dev/null
+++ b/tests/test_0130.out
@@ -0,0 +1,19 @@
+%p(basic) %d(0) %f(basic) %h(.) %H(basic) %P() %m(755) %M(drwxr-xr-x) %y(d)
+%p(basic/a) %d(1) %f(a) %h(basic) %H(basic) %P(a) %m(644) %M(-rw-r--r--) %y(f)
+%p(basic/b) %d(1) %f(b) %h(basic) %H(basic) %P(b) %m(644) %M(-rw-r--r--) %y(f)
+%p(basic/c) %d(1) %f(c) %h(basic) %H(basic) %P(c) %m(755) %M(drwxr-xr-x) %y(d)
+%p(basic/e) %d(1) %f(e) %h(basic) %H(basic) %P(e) %m(755) %M(drwxr-xr-x) %y(d)
+%p(basic/g) %d(1) %f(g) %h(basic) %H(basic) %P(g) %m(755) %M(drwxr-xr-x) %y(d)
+%p(basic/i) %d(1) %f(i) %h(basic) %H(basic) %P(i) %m(755) %M(drwxr-xr-x) %y(d)
+%p(basic/j) %d(1) %f(j) %h(basic) %H(basic) %P(j) %m(755) %M(drwxr-xr-x) %y(d)
+%p(basic/k) %d(1) %f(k) %h(basic) %H(basic) %P(k) %m(755) %M(drwxr-xr-x) %y(d)
+%p(basic/l) %d(1) %f(l) %h(basic) %H(basic) %P(l) %m(755) %M(drwxr-xr-x) %y(d)
+%p(basic/c/d) %d(2) %f(d) %h(basic/c) %H(basic) %P(c/d) %m(644) %M(-rw-r--r--) %y(f)
+%p(basic/e/f) %d(2) %f(f) %h(basic/e) %H(basic) %P(e/f) %m(644) %M(-rw-r--r--) %y(f)
+%p(basic/g/h) %d(2) %f(h) %h(basic/g) %H(basic) %P(g/h) %m(755) %M(drwxr-xr-x) %y(d)
+%p(basic/j/foo) %d(2) %f(foo) %h(basic/j) %H(basic) %P(j/foo) %m(644) %M(-rw-r--r--) %y(f)
+%p(basic/k/foo) %d(2) %f(foo) %h(basic/k) %H(basic) %P(k/foo) %m(755) %M(drwxr-xr-x) %y(d)
+%p(basic/l/foo) %d(2) %f(foo) %h(basic/l) %H(basic) %P(l/foo) %m(755) %M(drwxr-xr-x) %y(d)
+%p(basic/k/foo/bar) %d(3) %f(bar) %h(basic/k/foo) %H(basic) %P(k/foo/bar) %m(644) %M(-rw-r--r--) %y(f)
+%p(basic/l/foo/bar) %d(3) %f(bar) %h(basic/l/foo) %H(basic) %P(l/foo/bar) %m(755) %M(drwxr-xr-x) %y(d)
+%p(basic/l/foo/bar/baz) %d(4) %f(baz) %h(basic/l/foo/bar) %H(basic) %P(l/foo/bar/baz) %m(644) %M(-rw-r--r--) %y(f)
diff --git a/tests/test_0131.out b/tests/test_0131.out
new file mode 100644
index 0000000..5571971
--- /dev/null
+++ b/tests/test_0131.out
@@ -0,0 +1 @@
+(/)/(/)
diff --git a/tests/test_0132.out b/tests/test_0132.out
new file mode 100644
index 0000000..60710e5
--- /dev/null
+++ b/tests/test_0132.out
@@ -0,0 +1 @@
+(/)/(///)
diff --git a/tests/test_0133.out b/tests/test_0133.out
new file mode 100644
index 0000000..0aa4ffc
--- /dev/null
+++ b/tests/test_0133.out
@@ -0,0 +1,19 @@
+(basic)/(a)
+(basic)/(b)
+(basic)/(c)
+(basic)/(e)
+(basic)/(g)
+(basic)/(i)
+(basic)/(j)
+(basic)/(k)
+(basic)/(l)
+(.)/(basic/)
+(basic/c)/(d)
+(basic/e)/(f)
+(basic/g)/(h)
+(basic/j)/(foo)
+(basic/k)/(foo)
+(basic/l)/(foo)
+(basic/k/foo)/(bar)
+(basic/l/foo)/(bar)
+(basic/l/foo/bar)/(baz)
diff --git a/tests/test_0134.out b/tests/test_0134.out
new file mode 100644
index 0000000..cbb54a8
--- /dev/null
+++ b/tests/test_0134.out
@@ -0,0 +1,19 @@
+(basic//)/(a)
+(basic//)/(b)
+(basic//)/(c)
+(basic//)/(e)
+(basic//)/(g)
+(basic//)/(i)
+(basic//)/(j)
+(basic//)/(k)
+(basic//)/(l)
+(.)/(basic///)
+(basic///c)/(d)
+(basic///e)/(f)
+(basic///g)/(h)
+(basic///j)/(foo)
+(basic///k)/(foo)
+(basic///l)/(foo)
+(basic///k/foo)/(bar)
+(basic///l/foo)/(bar)
+(basic///l/foo/bar)/(baz)
diff --git a/tests/test_0135.out b/tests/test_0135.out
new file mode 100644
index 0000000..1a92b6e
--- /dev/null
+++ b/tests/test_0135.out
@@ -0,0 +1,19 @@
+|basic | +00 0755
+|basic/a | +01 0644
+|basic/b | +01 0644
+|basic/c | +01 0755
+|basic/e | +01 0755
+|basic/g | +01 0755
+|basic/i | +01 0755
+|basic/j | +01 0755
+|basic/k | +01 0755
+|basic/l | +01 0755
+|basic/c/d | +02 0644
+|basic/e/f | +02 0644
+|basic/g/h | +02 0755
+|basic/j/fo| +02 0644
+|basic/k/fo| +02 0755
+|basic/k/fo| +03 0644
+|basic/l/fo| +02 0755
+|basic/l/fo| +03 0755
+|basic/l/fo| +04 0644
diff --git a/tests/test_0136.out b/tests/test_0136.out
new file mode 100644
index 0000000..94fa833
--- /dev/null
+++ b/tests/test_0136.out
@@ -0,0 +1,10 @@
+(links) () d d
+(links/a) () f f
+(links/b) (a) l f
+(links/c) () f f
+(links/d) () d d
+(links/d/e) () d d
+(links/h) (d/e) l d
+(links/d/e/f) () d d
+(links/d/e/i) (q) l N
+(links/d/e/g) (../../d) l d
diff --git a/tests/test_0137.out b/tests/test_0137.out
new file mode 100644
index 0000000..20ea120
--- /dev/null
+++ b/tests/test_0137.out
@@ -0,0 +1 @@
+8 8I8I18