Skip to content

Commit

Permalink
Merge commit '5891ea97cdda63931f7d911d9c779d00eaf4f3bf'
Browse files Browse the repository at this point in the history
  • Loading branch information
davidanthoff committed Feb 11, 2023
2 parents 053086c + 5891ea9 commit 389eb9f
Showing 1 changed file with 20 additions and 2 deletions.
22 changes: 20 additions & 2 deletions packages/TestItemServer/src/TestItemServer.jl
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,6 @@ function run_testitem_handler(conn, params::TestserverRunTestitemRequestParams)
end
end

@info "AND WE GOT PAST THIS"

mod = Core.eval(Main, :(module $(gensym()) end))

if params.useDefaultUsings
Expand Down Expand Up @@ -191,6 +189,26 @@ function run_testitem_handler(conn, params::TestserverRunTestitemRequestParams)
end
end

for i in params.testsetups
try
Core.eval(mod, :(using ..Testsetups: $(Symbol(i))))
catch
return TestserverRunTestitemRequestParamsReturn(
"errored",
[
TestMessage(
"Unable to load the `$i` testsetup.",
Location(
params.uri,
Range(Position(params.line, 0), Position(params.line, 0))
)
)
],
nothing
)
end
end

filepath = uri2filepath(params.uri)

code = string('\n'^params.line, ' '^params.column, params.code)
Expand Down

0 comments on commit 389eb9f

Please sign in to comment.