|
GrafX2 2.9.3227
The ultimate 256-color painting program
|
Unit tests. More...
#include <stdlib.h>#include <string.h>#include "tests.h"#include "../struct.h"#include "../io.h"#include "../realpath.h"#include "../gfx2mem.h"#include "../gfx2log.h"
Include dependency graph for testio.c:Data Structures | |
| struct | dir_callback_data |
| data structure for For_each_directory_entry() callback More... | |
Functions | |
| int | Test_Read_Write_byte (char *errmsg) |
| int | Test_Read_Write_word (char *errmsg) |
| int | Test_Read_Write_dword (char *errmsg) |
| int | Test_Read_Write_bytes (char *errmsg) |
| static void | directory_callback (void *pdata, const char *filename, const word *unicode_filename, byte is_file, byte is_directory, byte is_hidden) |
| callback for For_each_directory_entry() More... | |
| int | Test_File_exists (char *errmsg) |
| int | Test_Realpath (char *errmsg) |
| int | Test_Calculate_relative_path (char *errmsg) |
Unit tests.
| int Test_Read_Write_byte | ( | char * | errmsg | ) |
References ERRMSG_LENGTH, NULL, PATH_SEPARATOR, Read_byte(), Remove_path(), tmpdir, and Write_byte().
| int Test_Read_Write_word | ( | char * | errmsg | ) |
References ERRMSG_LENGTH, NULL, PATH_SEPARATOR, Read_byte(), Read_word_be(), Read_word_le(), Remove_path(), tmpdir, Write_byte(), Write_word_be(), and Write_word_le().
| int Test_Read_Write_dword | ( | char * | errmsg | ) |
References ERRMSG_LENGTH, NULL, PATH_SEPARATOR, Read_byte(), Read_dword_be(), Read_dword_le(), Remove_path(), tmpdir, Write_byte(), Write_dword_be(), and Write_dword_le().
| int Test_Read_Write_bytes | ( | char * | errmsg | ) |
|
static |
callback for For_each_directory_entry()
References dir_callback_data::filename, GFX2_DEBUG, GFX2_Log(), and dir_callback_data::result.
Referenced by Test_File_exists().
| int Test_File_exists | ( | char * | errmsg | ) |
| int Test_Realpath | ( | char * | errmsg | ) |
References ERRMSG_LENGTH, GFX2_DEBUG, GFX2_Log(), NULL, Realpath(), Remove_path(), and tmpdir.
| int Test_Calculate_relative_path | ( | char * | errmsg | ) |
References Calculate_relative_path(), ERRMSG_LENGTH, GFX2_DEBUG, GFX2_Log(), NULL, PATH_SEPARATOR, and tmpdir.