@@ -10,6 +10,8 @@ using Test
1010import KNITRO
1111import MathOptInterface as MOI
1212
13+ const LICENSE_MANAGER = KNITRO. LMcontext ()
14+
1315function runtests ()
1416 for name in names (@__MODULE__ ; all= true )
1517 if startswith (" $(name) " , " test_" )
@@ -22,7 +24,9 @@ function runtests()
2224end
2325
2426function test_runtests ()
25- model = MOI. instantiate (KNITRO. Optimizer)
27+ model = MOI. instantiate (
28+ () -> KNITRO. Optimizer (; license_manager= LICENSE_MANAGER),
29+ )
2630 config = MOI. Test. Config (
2731 atol= 1e-3 ,
2832 rtol= 1e-3 ,
@@ -57,8 +61,11 @@ function test_MOI_Test_cached()
5761 r" ^test_conic_SecondOrderCone_out_of_order$" ,
5862 r" ^test_constraint_PrimalStart_DualStart_SecondOrderCone$" ,
5963 ]
60- model =
61- MOI. instantiate (KNITRO. Optimizer; with_bridge_type= Float64, with_cache_type= Float64)
64+ model = MOI. instantiate (
65+ () -> KNITRO. Optimizer (; license_manager= LICENSE_MANAGER);
66+ with_bridge_type= Float64,
67+ with_cache_type= Float64,
68+ )
6269 MOI. set (model, MOI. Silent (), true )
6370 config = MOI. Test. Config (
6471 atol= 2e-3 ,
0 commit comments