Skip to content
Snippets Groups Projects
Commit 4af147a8 authored by Etienne Kneuss's avatar Etienne Kneuss
Browse files

Correctly shutdown solver factories used in tests

parent 9afef91b
Branches
Tags
No related merge requests found
...@@ -79,8 +79,8 @@ class StablePrintingSuite extends LeonTestSuite { ...@@ -79,8 +79,8 @@ class StablePrintingSuite extends LeonTestSuite {
if (j.rules.size < depth) { if (j.rules.size < depth) {
for ((ci, i) <- chooses.zipWithIndex if j.choosesToProcess(i) || j.choosesToProcess.isEmpty) { for ((ci, i) <- chooses.zipWithIndex if j.choosesToProcess(i) || j.choosesToProcess.isEmpty) {
val synthesizer = new Synthesizer(ctx, pgm, ci, opts) val synthesizer = new Synthesizer(ctx, pgm, ci, opts)
val sctx = SynthesisContext.fromSynthesizer(synthesizer) val sctx = synthesizer.sctx
try { try {
val search = synthesizer.getSearch val search = synthesizer.getSearch
val hctx = SearchContext(sctx, ci, search.g.root, search) val hctx = SearchContext(sctx, ci, search.g.root, search)
val problem = ci.problem val problem = ci.problem
......
...@@ -104,6 +104,8 @@ class SynthesisSuite extends LeonTestSuite { ...@@ -104,6 +104,8 @@ class SynthesisSuite extends LeonTestSuite {
val sols = search.search(sctx) val sols = search.search(sctx)
sctx.solverFactory.shutdown()
if(sols.isEmpty) { if(sols.isEmpty) {
fail("No solution") fail("No solution")
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment