summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@tavianator.com>2017-09-06 22:05:04 -0400
committerTavian Barnes <tavianator@tavianator.com>2017-09-06 22:05:04 -0400
commit80eec18020f531abbdb2abbb919ab6c6fa34107c (patch)
treea12a50128e4ddab1a5b2ef2d6d9ddba200170fa9
parente05826cc75949203ca2a9135cb52af8fa1481c83 (diff)
downloadbfs-80eec18020f531abbdb2abbb919ab6c6fa34107c.tar.xz
tests: Test hardlinks to symlinks
-rwxr-xr-xtests.sh2
-rw-r--r--tests/test_H_samefile_broken.out1
-rw-r--r--tests/test_L.out2
-rw-r--r--tests/test_L_depth.out2
-rw-r--r--tests/test_L_xtype_l.out2
-rw-r--r--tests/test_colors.out2
-rw-r--r--tests/test_follow.out2
-rw-r--r--tests/test_printf_types.out2
-rw-r--r--tests/test_samefile_broken.out1
-rw-r--r--tests/test_samefile_symlink.out1
-rw-r--r--tests/test_xtype_f.out1
-rw-r--r--tests/test_xtype_l.out1
-rw-r--r--tests/test_xtype_multi.out1
13 files changed, 20 insertions, 0 deletions
diff --git a/tests.sh b/tests.sh
index 5729bb7..620bc2a 100755
--- a/tests.sh
+++ b/tests.sh
@@ -75,7 +75,9 @@ function make_links() {
touchp "$1/file"
ln -s file "$1/symlink"
ln "$1/file" "$1/hardlink"
+ ln -P "$1/symlink" "$1/hardsymlink"
ln -s nowhere "$1/broken"
+ ln -P "$1/broken" "$1/hardbroken"
ln -s symlink/file "$1/notdir"
ln -s loop "$1/loop"
mkdir -p "$1/deeply/nested/dir"
diff --git a/tests/test_H_samefile_broken.out b/tests/test_H_samefile_broken.out
index 21d6316..01a6f1e 100644
--- a/tests/test_H_samefile_broken.out
+++ b/tests/test_H_samefile_broken.out
@@ -1 +1,2 @@
links/broken
+links/hardbroken
diff --git a/tests/test_L.out b/tests/test_L.out
index dc88380..d96be2a 100644
--- a/tests/test_L.out
+++ b/tests/test_L.out
@@ -2,7 +2,9 @@ links
links/broken
links/deeply
links/file
+links/hardbroken
links/hardlink
+links/hardsymlink
links/notdir
links/skip
links/symlink
diff --git a/tests/test_L_depth.out b/tests/test_L_depth.out
index dc88380..d96be2a 100644
--- a/tests/test_L_depth.out
+++ b/tests/test_L_depth.out
@@ -2,7 +2,9 @@ links
links/broken
links/deeply
links/file
+links/hardbroken
links/hardlink
+links/hardsymlink
links/notdir
links/skip
links/symlink
diff --git a/tests/test_L_xtype_l.out b/tests/test_L_xtype_l.out
index 5773878..bfb5bec 100644
--- a/tests/test_L_xtype_l.out
+++ b/tests/test_L_xtype_l.out
@@ -1,4 +1,6 @@
links/broken
+links/hardbroken
+links/hardsymlink
links/notdir
links/skip
links/symlink
diff --git a/tests/test_colors.out b/tests/test_colors.out
index 6f8c534..6ff097f 100644
--- a/tests/test_colors.out
+++ b/tests/test_colors.out
@@ -1,8 +1,10 @@
links
links/deeply
+links/hardsymlink
links/skip
links/symlink
links/broken
+links/hardbroken
links/loop
links/notdir
links/file
diff --git a/tests/test_follow.out b/tests/test_follow.out
index dc88380..d96be2a 100644
--- a/tests/test_follow.out
+++ b/tests/test_follow.out
@@ -2,7 +2,9 @@ links
links/broken
links/deeply
links/file
+links/hardbroken
links/hardlink
+links/hardsymlink
links/notdir
links/skip
links/symlink
diff --git a/tests/test_printf_types.out b/tests/test_printf_types.out
index b548b10..4b19b34 100644
--- a/tests/test_printf_types.out
+++ b/tests/test_printf_types.out
@@ -2,7 +2,9 @@
(links/broken) (nowhere) l N
(links/deeply) () d d
(links/file) () f f
+(links/hardbroken) (nowhere) l N
(links/hardlink) () f f
+(links/hardsymlink) (file) l f
(links/loop) (loop) l L
(links/symlink) (file) l f
(links/deeply/nested) () d d
diff --git a/tests/test_samefile_broken.out b/tests/test_samefile_broken.out
index 21d6316..01a6f1e 100644
--- a/tests/test_samefile_broken.out
+++ b/tests/test_samefile_broken.out
@@ -1 +1,2 @@
links/broken
+links/hardbroken
diff --git a/tests/test_samefile_symlink.out b/tests/test_samefile_symlink.out
index 299a572..08eb8ab 100644
--- a/tests/test_samefile_symlink.out
+++ b/tests/test_samefile_symlink.out
@@ -1 +1,2 @@
+links/hardsymlink
links/symlink
diff --git a/tests/test_xtype_f.out b/tests/test_xtype_f.out
index 222ac78..35460e6 100644
--- a/tests/test_xtype_f.out
+++ b/tests/test_xtype_f.out
@@ -1,3 +1,4 @@
links/file
links/hardlink
+links/hardsymlink
links/symlink
diff --git a/tests/test_xtype_l.out b/tests/test_xtype_l.out
index 8b0a404..7c2bb3a 100644
--- a/tests/test_xtype_l.out
+++ b/tests/test_xtype_l.out
@@ -1,2 +1,3 @@
links/broken
+links/hardbroken
links/notdir
diff --git a/tests/test_xtype_multi.out b/tests/test_xtype_multi.out
index f9847db..ce52e19 100644
--- a/tests/test_xtype_multi.out
+++ b/tests/test_xtype_multi.out
@@ -2,6 +2,7 @@ links
links/deeply
links/file
links/hardlink
+links/hardsymlink
links/skip
links/symlink
links/deeply/nested