1
0
Fork 0
libfort/tests/tests.h

43 lines
757 B
C
Raw Normal View History

2018-01-01 09:26:34 +01:00
#ifndef TESTS_H
#define TESTS_H
#include <stdarg.h>
#include <stddef.h>
#include <setjmp.h>
2018-03-19 21:07:18 +01:00
#include "fort_impl.h"
#include <assert.h>
2018-01-01 09:26:34 +01:00
#define WHEN(...)
#define THEN(...)
2018-03-20 18:57:50 +01:00
#define SCENARIO(...)
2018-01-01 09:26:34 +01:00
2018-03-19 21:07:18 +01:00
/* Test cases */
void test_vector_basic(void);
void test_string_buffer(void);
void test_table_sizes(void);
void test_table_geometry(void);
void test_table_basic(void);
2018-03-20 18:57:50 +01:00
void test_table_write(void);
2018-03-19 21:07:18 +01:00
void test_table_border_style(void);
void test_table_options(void);
2018-01-01 09:26:34 +01:00
struct test_case
{
char name [128];
2018-03-19 21:07:18 +01:00
void (*test)(void);
};
2018-03-19 21:07:18 +01:00
/*
* Test utility funcitons
*/
#define assert_true(args) assert(args)
2018-01-01 09:26:34 +01:00
2018-03-19 21:07:18 +01:00
int set_test_options_for_table(FTABLE *table);
int set_test_options_as_default();
FTABLE *create_test_int_table(int set_test_opts);
2018-01-01 09:26:34 +01:00
#endif // TESTS_H