From 4eeec6a80054cadfac72a4ac83f7bcbf36b7732f Mon Sep 17 00:00:00 2001 From: Niko Savola Date: Fri, 20 Oct 2023 09:21:22 -0700 Subject: [PATCH] Use temporary directory factory in session scope tests --- gplugins/klayout/tests/test_plot_nets.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gplugins/klayout/tests/test_plot_nets.py b/gplugins/klayout/tests/test_plot_nets.py index ae4f8e6c..ad8d2008 100644 --- a/gplugins/klayout/tests/test_plot_nets.py +++ b/gplugins/klayout/tests/test_plot_nets.py @@ -8,10 +8,10 @@ @pytest.fixture(scope="session") -def klayout_netlist(tmp_path) -> str: +def klayout_netlist(tmpdir_factory) -> str: """Get KLayout netlist file for `pads_correct`. Cached for session scope.""" + tmp_path = tmpdir_factory.mktemp("data") c = pads_correct() - gdspath = c.write_gds(gdsdir=tmp_path) l2n = get_l2n(gdspath) netlist_path = str(Path(tmp_path) / f"{c.name}.txt")