X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs2.git;a=blobdiff_plain;f=direct%2Ftimothy_tests%2Fquick_tests%2Ftest_yaffs_remount_force_off_read_only_off.c;fp=direct%2Ftimothy_tests%2Fquick_tests%2Ftest_yaffs_sync_ENOENT.c;h=e86f9239a71223d5f3bae3f8fa87f31254567f3a;hp=2f1792d4ac4cb789468014dc084126e1ba6190c1;hb=239fd86892c59299042eabf617309a2d2ddf700b;hpb=7b53d290e92e619a315399ba49aadf6b40e13660 diff --git a/direct/timothy_tests/quick_tests/test_yaffs_sync_ENOENT.c b/direct/timothy_tests/quick_tests/test_yaffs_remount_force_off_read_only_off.c similarity index 55% rename from direct/timothy_tests/quick_tests/test_yaffs_sync_ENOENT.c rename to direct/timothy_tests/quick_tests/test_yaffs_remount_force_off_read_only_off.c index 2f1792d..e86f923 100644 --- a/direct/timothy_tests/quick_tests/test_yaffs_sync_ENOENT.c +++ b/direct/timothy_tests/quick_tests/test_yaffs_remount_force_off_read_only_off.c @@ -11,33 +11,35 @@ * published by the Free Software Foundation. */ -#include "test_yaffs_sync_ENOENT.h" +#include "test_yaffs_remount_force_off_read_only_off.h" +int test_yaffs_remount_force_off_read_only_off(void) +{ + int output = -1; + int error_code =0; + + + output = yaffs_remount(YAFFS_MOUNT_POINT,0,0); + if (output>=0){ + return 1; + } else { + print_message("failed to remount\n",2); + return -1; + } +} -int test_yaffs_sync_ENOENT(void) +int test_yaffs_remount_force_off_read_only_off_clean(void) { - int error_code=-1; - int output = yaffs_sync("yaffs2/non-existing-file"); - + int output=0; + int error_code =0; + output= yaffs_mount(YAFFS_MOUNT_POINT); if (output<0){ error_code=yaffs_get_error(); - if (abs(error_code)==ENOENT){ + if (abs(error_code) == EBUSY){ return 1; } else { - print_message("returned error does not match the the expected error\n",2); return -1; } - } else { - print_message("synced a file in a non-existing directory (which is a bad thing)\n",2); - return -1; - } - - -} - - -int test_yaffs_sync_ENOENT_clean(void) -{ + } return 1; } -