File tree Expand file tree Collapse file tree 2 files changed +11
-15
lines changed Expand file tree Collapse file tree 2 files changed +11
-15
lines changed Original file line number Diff line number Diff line change 24
24
25
25
#include "scip/nodesel_dfs.h"
26
26
#include "scip/cons_integral.h"
27
+ #include <locale.h>
27
28
28
29
/** execution method of presolver */
29
30
static
@@ -165,3 +166,13 @@ void TESTsetTestfilename(
165
166
else
166
167
(void )SCIPsnprintf (filename , SCIP_MAXSTRLEN , testfile );
167
168
}
169
+
170
+ /* ensure we run with C locale */
171
+ #ifdef __GNUC__
172
+ __attribute__((constructor ))
173
+ static
174
+ void TESTsetlocale (void )
175
+ {
176
+ setlocale (LC_ALL , "C" );
177
+ }
178
+ #endif
Original file line number Diff line number Diff line change @@ -22,7 +22,6 @@ void TESTsetTestfilename(
22
22
* be available every test.
23
23
* */
24
24
#include "scip_test.c"
25
- #include "locale.h"
26
25
27
26
#ifdef __GNUC__
28
27
#pragma GCC diagnostic ignored "-Wredundant-decls"
@@ -49,17 +48,3 @@ void TESTsetTestfilename(
49
48
} \
50
49
} \
51
50
while( FALSE )
52
-
53
- CR_API int main (int argc , char * argv []) {
54
- struct criterion_test_set * tests = criterion_initialize ();
55
-
56
- int result = 0 ;
57
- if (criterion_handle_args (argc , argv , true))
58
- {
59
- setlocale (LC_ALL , "C" );
60
- result = !criterion_run_all_tests (tests );
61
- }
62
-
63
- criterion_finalize (tests );
64
- return result ;
65
- }
You can’t perform that action at this time.
0 commit comments