()
| 378 | |
| 379 | #[test] |
| 380 | fn test_run_script() { |
| 381 | interpreter().enter(|vm| { |
| 382 | vm.unwrap_pyresult((|| { |
| 383 | let scope = vm.new_scope_with_main()?; |
| 384 | // test file run |
| 385 | run_file(vm, scope, "extra_tests/snippets/dir_main/__main__.py")?; |
| 386 | |
| 387 | #[cfg(feature = "host_env")] |
| 388 | { |
| 389 | let scope = vm.new_scope_with_main()?; |
| 390 | // test module run (directory with __main__.py) |
| 391 | run_file(vm, scope, "extra_tests/snippets/dir_main")?; |
| 392 | } |
| 393 | |
| 394 | Ok(()) |
| 395 | })()); |
| 396 | }) |
| 397 | } |
| 398 | } |
nothing calls this directly
no test coverage detected