comparison tests.c @ 469:fe5b803ae449

Rename the global variable th_verbosityLevel to th_verbosity.
author Matti Hamalainen <ccr@tnsp.org>
date Mon, 04 Jun 2018 02:41:27 +0300
parents 6d44592cdab1
children 185a6ea03fea
comparison
equal deleted inserted replaced
468:bbe3c9175d77 469:fe5b803ae449
47 static const int arg_nopts = sizeof(arg_opts) / sizeof(arg_opts[0]); 47 static const int arg_nopts = sizeof(arg_opts) / sizeof(arg_opts[0]);
48 48
49 49
50 BOOL tprintv(const int level, const char *fmt, va_list ap) 50 BOOL tprintv(const int level, const char *fmt, va_list ap)
51 { 51 {
52 if (level <= th_verbosityLevel) 52 if (level <= th_verbosity)
53 { 53 {
54 vfprintf(stdout, fmt, ap); 54 vfprintf(stdout, fmt, ap);
55 return TRUE; 55 return TRUE;
56 } 56 }
57 else 57 else
85 arg_show_help(); 85 arg_show_help();
86 exit(0); 86 exit(0);
87 break; 87 break;
88 88
89 case 1: 89 case 1:
90 th_verbosityLevel++; 90 th_verbosity++;
91 break; 91 break;
92 92
93 case 2: 93 case 2:
94 { 94 {
95 BOOL ret = TRUE; 95 BOOL ret = TRUE;
333 333
334 // 334 //
335 // Initialization 335 // Initialization
336 // 336 //
337 th_init("th-test", "th-libs unit tests", "0.1", NULL, NULL); 337 th_init("th-test", "th-libs unit tests", "0.1", NULL, NULL);
338 th_verbosityLevel = 0; 338 th_verbosity = 0;
339 339
340 if (sizeof(char) != sizeof(unsigned char)) 340 if (sizeof(char) != sizeof(unsigned char))
341 { 341 {
342 THERR("sizeof(char) != sizeof(unsigned char)???\n"); 342 THERR("sizeof(char) != sizeof(unsigned char)???\n");
343 return -1; 343 return -1;