diff options
author | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2023-02-12 12:28:40 +0100 |
---|---|---|
committer | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2023-02-12 12:28:40 +0100 |
commit | b635c78530d5d7f27f9805790c1f7ca227959177 (patch) | |
tree | 9581e10402219bcae6009c81087a9f525e8cece3 /bin/gensquashfs | |
parent | 9a7a07d047b6baffb095f16074402630fe2f0270 (diff) |
libtar: Add a test for the tar writing code
Generate a simple tarball and compare it with a reference.
Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
Diffstat (limited to 'bin/gensquashfs')
-rw-r--r-- | bin/gensquashfs/test/fstree_glob1.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/bin/gensquashfs/test/fstree_glob1.c b/bin/gensquashfs/test/fstree_glob1.c index 5f4fdfe..2d3cb80 100644 --- a/bin/gensquashfs/test/fstree_glob1.c +++ b/bin/gensquashfs/test/fstree_glob1.c @@ -202,6 +202,13 @@ static void check_hierarchy(tree_node_t *root, bool subdir, bool recursive) n = n->next; TEST_NOT_NULL(n); + TEST_STR_EQUAL(n->name, "write"); + TEST_ASSERT(S_ISDIR(n->mode)); + TEST_ASSERT(n->parent == parentdir); + TEST_NULL(n->data.dir.children); + + n = n->next; + TEST_NOT_NULL(n); TEST_STR_EQUAL(n->name, "xattr"); TEST_ASSERT(S_ISDIR(n->mode)); TEST_ASSERT(n->parent == parentdir); |