From d602b9d71e1815607f5132ff8c8571bffaa2fccf Mon Sep 17 00:00:00 2001 From: jist <95856749+george0st@users.noreply.github.com> Date: Tue, 22 Oct 2024 14:54:31 +0200 Subject: [PATCH 1/2] repair unit tests --- tests/test_graph.py | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/tests/test_graph.py b/tests/test_graph.py index b51d9e5..2b35e55 100644 --- a/tests/test_graph.py +++ b/tests/test_graph.py @@ -206,28 +206,22 @@ def test_graph_percentile(self): setup=RunSetup(duration_second=2, start_delay=0, parameters={"percentile": 0.95}) generator.run_bulk_executor([[1,1], [1,5]], [[4,4],[8,4],[16,4]], setup) - generator.create_graph_perf(self.OUTPUT_ADR) - - today = datetime.datetime.now().strftime("%Y-%m-%d") - - # check relevant files - file=glob.glob(path.join(self.OUTPUT_ADR, "graph-perf", "2 sec", today, f"PRF-test_percentile-*-bulk-*.png")) - self.assertTrue(len(file)==2) - print(file[0]) + output=generator.create_graph_perf(self.OUTPUT_ADR) + self.assertTrue(len(output)==2) def test_graph_onlynew(self): generator = ParallelExecutor(prf_test, label="test_percentile", detail_output=True, - output_file=path.join(self.OUTPUT_ADR, "only_new", "perf_test_percentile.txt")) + output_file=path.join(self.OUTPUT_ADR, "perf_test_only_new.txt")) setup=RunSetup(duration_second=2, start_delay=0, parameters={"percentile": 0.95}) generator.run_bulk_executor([[1,1]], [[1,1]], setup) - output=generator.create_graph_perf(self.OUTPUT_ADR, only_new = True) + output=generator.create_graph_perf(path.join(self.OUTPUT_ADR, "only_new"), only_new = True) self.assertTrue(len(output) == 1) - output=generator.create_graph_perf(self.OUTPUT_ADR, only_new = True) + output=generator.create_graph_perf(path.join(self.OUTPUT_ADR, "only_new"), only_new = True) self.assertTrue(len(output) == 0) From 314d65d0a5e7b3d50c38b71da4553ef5a7c9747f Mon Sep 17 00:00:00 2001 From: jist <95856749+george0st@users.noreply.github.com> Date: Tue, 22 Oct 2024 14:54:50 +0200 Subject: [PATCH 2/2] Update version.py --- qgate_perf/version.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qgate_perf/version.py b/qgate_perf/version.py index a33d23a..d5c4623 100644 --- a/qgate_perf/version.py +++ b/qgate_perf/version.py @@ -1,3 +1,3 @@ # Store the version here so: -__version__ = '0.4.41' \ No newline at end of file +__version__ = '0.4.42' \ No newline at end of file