()
| 1434 | |
| 1435 | |
| 1436 | def test_script_raise_on_interrupt(): |
| 1437 | ip = get_ipython() |
| 1438 | |
| 1439 | with pytest.raises(CalledProcessError): |
| 1440 | thread = Thread(target=_interrupt_after_1s) |
| 1441 | thread.start() |
| 1442 | ip.run_cell_magic( |
| 1443 | "script", f"{sys.executable}", "from time import sleep; sleep(2)" |
| 1444 | ) |
| 1445 | thread.join() |
| 1446 | |
| 1447 | |
| 1448 | def test_script_do_not_raise_on_interrupt(): |
nothing calls this directly
no test coverage detected
searching dependent graphs…