| 1 |
/* |
| 2 |
* FCML - Free Code Manipulation Library. |
| 3 |
* Copyright (C) 2010-2024 Slawomir Wojtasiak |
| 4 |
* |
| 5 |
* This library is free software; you can redistribute it and/or |
| 6 |
* modify it under the terms of the GNU Lesser General Public |
| 7 |
* License as published by the Free Software Foundation; either |
| 8 |
* version 2.1 of the License, or (at your option) any later version. |
| 9 |
* |
| 10 |
* This library is distributed in the hope that it will be useful, |
| 11 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 13 |
* Lesser General Public License for more details. |
| 14 |
* |
| 15 |
* You should have received a copy of the GNU Lesser General Public |
| 16 |
* License along with this library; if not, write to the Free Software |
| 17 |
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA |
| 18 |
*/ |
| 19 |
|
| 20 |
#include <stdio.h> |
| 21 |
#include <stdlib.h> |
| 22 |
|
| 23 |
#include <fcml_stf.h> |
| 24 |
|
| 25 |
/* Tests.*/ |
| 26 |
#include "modrm_encoder_t.h" |
| 27 |
#include "modrm_decoder_t.h" |
| 28 |
#include "stream_t.h" |
| 29 |
#include "coll_t.h" |
| 30 |
#include "utils_t.h" |
| 31 |
#include "intel_parser_t.h" |
| 32 |
#include "gas_parser_t.h" |
| 33 |
#include "mnemonic_parser_t.h" |
| 34 |
#include "lag_assembler_t.h" |
| 35 |
#include "env_t.h" |
| 36 |
#include "ceh_t.h" |
| 37 |
#include "common_utils_t.h" |
| 38 |
#include "instruction_chooser_t.h" |
| 39 |
#include "symbols_t.h" |
| 40 |
|
| 41 |
fcml_stf_test_suite *fcml_arr_suites[] = { |
| 42 |
&fctl_si_modrm_encoder, |
| 43 |
&fctl_si_modrm_decoder, |
| 44 |
&fctl_si_stream, |
| 45 |
&fcml_si_coll, |
| 46 |
&fcml_si_utils, |
| 47 |
&fcml_si_intel_parser, |
| 48 |
&fcml_si_gas_parser, |
| 49 |
&fcml_si_mnemonic_parser, |
| 50 |
&fcml_si_lag_assembler, |
| 51 |
&fcml_si_env, |
| 52 |
&fcml_si_ceh, |
| 53 |
&fcml_si_common_utils, |
| 54 |
&fcml_si_instruction_chooser, |
| 55 |
&fctl_si_symbols, |
| 56 |
FCML_STF_NULL_SUITE |
| 57 |
}; |
| 58 |
|
| 59 |
int main(int argc, char **argv) { |
| 60 |
|
| 61 |
/* Run tests.*/ |
| 62 |
fcml_bool result = fcml_stf_run_tests( FCML_TEXT( "Internal unit tests" ), |
| 63 |
fcml_arr_suites ); |
| 64 |
|
| 65 |
exit( result ? 0 : 1 ); |
| 66 |
} |