File tree Expand file tree Collapse file tree 1 file changed +13
-2
lines changed
Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Original file line number Diff line number Diff line change 2222# If present, the tests run only those submodules defined above. `General` is
2323# not a submodule, but it runs all of the top-level tests in MOI.
2424
25- import Test
26-
2725# This file gets called first. If it doesn't crash, all is well.
2826include (" issue980.jl" )
2927
@@ -33,6 +31,19 @@ MODULES_TO_TEST = get(
3331 " General;Benchmarks;Bridges;Bridges/Constraint;Bridges/Objective;Bridges/Variable;FileFormats;Nonlinear;Test;Utilities" ,
3432)
3533
34+ """
35+ include_with_method_redefinition_check(jl_filename)
36+
37+ This function runs `include(jl_filename)` with an additional check that there
38+ are no `WARNING: Method definition foo in module Foo overwritten` warnings.
39+
40+ It does this by piping `stderr` to a file, and then parsing the file.
41+
42+ One consequence is that `stderr` is not printed until the _end_ of this
43+ function. Thus, some warnings may appear in the wrong place.
44+
45+ This function requires Julia to be started with `--warn-overwrite=true`.
46+ """
3647function include_with_method_redefinition_check (jl_filename)
3748 stderr_filename = tempname ()
3849 open (stderr_filename, " w" ) do io
You can’t perform that action at this time.
0 commit comments