Skip to content

Commit 9b80126

Browse files
Fix test_entry.py::test_license_agr (#1381)
* changed exception type * test for operator usage and not construction * attempt to fix the test * shutdown default inprocess test server * Update tests/entry/test_entry.py --------- Co-authored-by: Paul Profizi <[email protected]>
1 parent fc61e25 commit 9b80126

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

tests/entry/test_entry.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,13 @@
1717
reason="Tests ANSYS_DPF_ACCEPT_LA",
1818
)
1919
def test_license_agr(restore_accept_la_env):
20+
dpf.server.shutdown_global_server()
2021
config = dpf.AvailableServerConfigs.InProcessServer
2122
init_val = os.environ["ANSYS_DPF_ACCEPT_LA"]
2223
del os.environ["ANSYS_DPF_ACCEPT_LA"]
2324
with pytest.raises(errors.DPFServerException):
2425
dpf.start_local_server(config=config, as_global=True)
25-
with pytest.raises(KeyError):
26+
with pytest.raises(errors.DPFServerException):
2627
dpf.Operator("stream_provider")
2728
os.environ["ANSYS_DPF_ACCEPT_LA"] = init_val
2829
dpf.start_local_server(config=config, as_global=True)

0 commit comments

Comments
 (0)