Running Yaffs Direct Tests

 

1 Background

This document is intended to provide a outline to the various tests that are incorporated into Yaffs Direct. Most of these tests were written as debug tools to test error response by various Yaffs functions. These and others can be used to check if Yaffs is working properly.

2 Running the tests

All of the test directories should have a Makefile. Run it to compile the test. The Readme.txt file should tell you how to run the tests.

3 Tests

  • is_yaffs_working_tests folder contains a the tests related to simply seeing if yaffs is working. There is only one test at the moment, test_1_yaffs_mount.c, which tests if yaffs will mount, create a file and be able to read the file after remounting.

  • stress_tester folder contains yaffs_tester.c which stress tests yaffs by opening and closing files at random. This test will run forever (or until it crashes).

  • handle_tests folder contains the test handle_tests.c which just creates files and duplicates the file handle.

  • The yaffs_and_linux_mirror_tests folder runs a yaffs operation and then compares the response the same command run under linux. This test is used to check that yaffs responds in expected manner with respect to linux.

  • quick_tests folder contains the quick_test which tests almost all of yaffs functions' error handling and error codes.

  • The threading folder contains the test_threading.c which tests the thread locking ability of yaffs.

 

The folder linux_tests contains the linux_test.c test which tests yaffs running under linux using the nandsim generator.