From 6a903440a96cb29c3bd4d21e92ed4d465b70741f Mon Sep 17 00:00:00 2001 From: Ovidiu Mircescu Date: Tue, 7 Sep 2021 14:35:58 +0200 Subject: [PATCH] Cleaning the containers in ssl tests. --- src/py2yacs/Test/Py2yacsTest.cxx | 1 + src/py2yacs/Test/testDeco.py | 4 ++++ src/yacsloader_swig/Test/testPynodeWithCache.py | 6 ++++++ 3 files changed, 11 insertions(+) diff --git a/src/py2yacs/Test/Py2yacsTest.cxx b/src/py2yacs/Test/Py2yacsTest.cxx index 4049c9107..8cea86323 100644 --- a/src/py2yacs/Test/Py2yacsTest.cxx +++ b/src/py2yacs/Test/Py2yacsTest.cxx @@ -299,6 +299,7 @@ void Py2yacsTest::schemaExec() CPPUNIT_ASSERT(pyVal); CPPUNIT_ASSERT(PyFloat_Check(pyVal)); CPPUNIT_ASSERT_DOUBLES_EQUAL(42., PyFloat_AsDouble(pyVal), 1.E-12); + p->shutdown(10); // kill all the containers } // Test the behaviour when there is an error in the python parser diff --git a/src/py2yacs/Test/testDeco.py b/src/py2yacs/Test/testDeco.py index 00f60a773..588c7ab13 100755 --- a/src/py2yacs/Test/testDeco.py +++ b/src/py2yacs/Test/testDeco.py @@ -52,6 +52,10 @@ class TestDeco(unittest.TestCase): resource_definition = resourceManager.GetResourceDefinition("localhost") self.assertEqual(resource_definition.nb_node, NB_NODE) + def tearDown(self): + cm = salome.lcc.getContainerManager() + cm.ShutdownContainers() + def test_t1(self): """ Schema: diff --git a/src/yacsloader_swig/Test/testPynodeWithCache.py b/src/yacsloader_swig/Test/testPynodeWithCache.py index b80dc9419..ce847d40a 100755 --- a/src/yacsloader_swig/Test/testPynodeWithCache.py +++ b/src/yacsloader_swig/Test/testPynodeWithCache.py @@ -21,6 +21,7 @@ import sys import pilot import SALOMERuntime +import salome import loader import unittest import tempfile @@ -37,6 +38,11 @@ class TestEdit(unittest.TestCase): self.e = pilot.ExecutorSwig() pass + def tearDown(self): + salome.salome_init() + cm = salome.lcc.getContainerManager() + cm.ShutdownContainers() + def test1(self): """ Test the conservation of the python context between two nodes sharing the same container. -- 2.39.2