@@ -146,8 +146,8 @@ version_added(::F) where {F} = v"0.10.5" # The default for any unlabeled tests.
146146 runtests(
147147 model::MOI.ModelLike,
148148 config::Config;
149- include::Vector{String} = String[],
150- exclude::Vector{String} = String[],
149+ include::Vector{Union{ String,Regex} } = String[],
150+ exclude::Vector{Union{ String,Regex} } = String[],
151151 warn_unsupported::Bool = false,
152152 exclude_tests_after::VersionNumber = v"999.0.0",
153153 )
@@ -158,10 +158,10 @@ Run all tests in `MathOptInterface.Test` on `model`.
158158
159159 * `config` is a [`Test.Config`](@ref) object that can be used to modify the
160160 behavior of tests.
161- * If `include` is not empty, only run tests that contain an element from
162- `include` in their name.
163- * If `exclude` is not empty, skip tests that contain an element from `exclude`
164- in their name.
161+ * If `include` is not empty, only run tests if an element from `include`
162+ `occursin` the name of the test .
163+ * If `exclude` is not empty, skip tests if an element from `exclude` `occursin `
164+ the name of the test .
165165 * `exclude` takes priority over `include`.
166166 * If `warn_unsupported` is `false`, `runtests` will silently skip tests that
167167 fail with a `MOI.NotAllowedError`, `MOI.UnsupportedError`, or
@@ -186,7 +186,7 @@ config = MathOptInterface.Test.Config()
186186MathOptInterface.Test.runtests(
187187 model,
188188 config;
189- include = ["test_linear_"],
189+ include = ["test_linear_", r"^test_model_Name \$ " ],
190190 exclude = ["VariablePrimalStart"],
191191 warn_unsupported = true,
192192 exclude_tests_after = v"0.10.5",
@@ -196,8 +196,8 @@ MathOptInterface.Test.runtests(
196196function runtests (
197197 model:: MOI.ModelLike ,
198198 config:: Config ;
199- include:: Vector{String} = String[],
200- exclude:: Vector{String} = String[],
199+ include:: Vector = String[],
200+ exclude:: Vector = String[],
201201 warn_unsupported:: Bool = false ,
202202 exclude_tests_after:: VersionNumber = v " 999.0.0" ,
203203)
0 commit comments