summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorLutz Mueller <lutz@users.sourceforge.net>2001-08-19 20:57:12 +0000
committerLutz Mueller <lutz@users.sourceforge.net>2001-08-19 20:57:12 +0000
commit70209f7e828ee8da1a4e526a41fd0f6fc920574f (patch)
treead2a1b137d79adc74c7d9db196cb386aa80b4be1 /tests
parent2904bec8814d0121555af6f71abd5d6c5d9cf246 (diff)
downloadlibgphoto2-70209f7e828ee8da1a4e526a41fd0f6fc920574f.tar.gz
2001-08-19 Lutz M�ller <urc8@rz.uni-karlsruhe.de>
* tests/test-filesys.c: Even more tests * libgphoto2/filesys.c: Fix remaining bugs. It should work now... git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@2015 67ed7778-7388-44ab-90cf-0a291f65f57c
Diffstat (limited to 'tests')
-rw-r--r--tests/.cvsignore1
-rw-r--r--tests/test-filesys.c15
2 files changed, 16 insertions, 0 deletions
diff --git a/tests/.cvsignore b/tests/.cvsignore
index 402f8a866..5c12492f1 100644
--- a/tests/.cvsignore
+++ b/tests/.cvsignore
@@ -1,6 +1,7 @@
Makefile.in
Makefile
test-gphoto2
+test-filesys
.libs
.deps
*.o
diff --git a/tests/test-filesys.c b/tests/test-filesys.c
index beaf39c40..d25050642 100644
--- a/tests/test-filesys.c
+++ b/tests/test-filesys.c
@@ -16,6 +16,21 @@ main (int argc, char **argv)
printf ("*** Creating file system...\n");
fs = gp_filesystem_new ();
+ printf ("*** Adding a file...\n");
+ CHECK (gp_filesystem_append (fs, "/", "my.file"));
+
+ gp_filesystem_dump (fs);
+
+ printf ("*** Removing this file...\n");
+ CHECK (gp_filesystem_delete (fs, "/", "my.file"));
+
+ gp_filesystem_dump (fs);
+
+ printf ("*** Removing /...\n");
+ CHECK (gp_filesystem_delete (fs, "/", NULL));
+
+ gp_filesystem_dump (fs);
+
printf ("*** Adding some files...\n");
CHECK (gp_filesystem_append (fs, "/", NULL));
CHECK (gp_filesystem_append (fs, "/whatever", NULL));