Line | |
---|
1 | /* |
---|
2 | * $Id$ |
---|
3 | * |
---|
4 | * [ Description ] |
---|
5 | * |
---|
6 | */ |
---|
7 | |
---|
8 | #include "Behavioural/@DIRECTORY/SelfTest/include/test.h" |
---|
9 | |
---|
10 | #define NB_PARAMS 0 |
---|
11 | |
---|
12 | void usage (string exec) |
---|
13 | { |
---|
14 | cerr << "<Usage> " << exec << " name_instance list_params" << endl |
---|
15 | << "list_params is :" << endl; |
---|
16 | // << " - size_data (unsigned int)" << endl |
---|
17 | // << " - nb_port (unsigned int)" << endl; |
---|
18 | |
---|
19 | exit (1); |
---|
20 | } |
---|
21 | |
---|
22 | #ifndef SYSTEMC |
---|
23 | int main (int argc, char * argv[]) |
---|
24 | #else |
---|
25 | int sc_main (int argc, char * argv[]) |
---|
26 | #endif |
---|
27 | { |
---|
28 | if (argc != 2+NB_PARAMS) |
---|
29 | usage (argv[0]); |
---|
30 | |
---|
31 | const string name = argv[1]; |
---|
32 | //const uint32_t size_data = atoi(argv[2]); |
---|
33 | //const uint32_t nb_port = atoi(argv[3]); |
---|
34 | |
---|
35 | try |
---|
36 | { |
---|
37 | morpheo::behavioural::@NAMESPACE_USE::Parameters param (//size_data, |
---|
38 | //nb_port |
---|
39 | ); |
---|
40 | |
---|
41 | cout << param.print(1); |
---|
42 | |
---|
43 | test (name,param); |
---|
44 | } |
---|
45 | catch (morpheo::ErrorMorpheo & error) |
---|
46 | { |
---|
47 | cout << "<" << name << "> : " << error.what (); |
---|
48 | return; |
---|
49 | } |
---|
50 | catch (...) |
---|
51 | { |
---|
52 | cerr << "<" << name << "> : This test must generate a error" << endl; |
---|
53 | exit (EXIT_FAILURE); |
---|
54 | } |
---|
55 | |
---|
56 | return (EXIT_SUCCESS); |
---|
57 | } |
---|
58 | |
---|
Note: See
TracBrowser
for help on using the repository browser.