Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[docs-beta-snippets] fix broken unit test in
module_from_spec
(#25037)
## Summary & Motivation The unit test that validates that our `docs_beta_snippets` example load uses the following: ``` spec = importlib.util.spec_from_file_location("module", file_path) assert spec is not None and spec.loader is not None module = importlib.util.module_from_spec(spec) try: spec.loader.exec_module(module) except Exception as e: pytest.fail(f"Failed to load {file_path}: {e!s}") ``` It appears that this doesn't play well with our loader functions: ``` all_assets = dg.load_assets_from_current_module() all_asset_checks = dg.load_asset_checks_from_current_module() ``` This pull request replaces these with hard-coded asset names--though admittedly this is less elegant. ## How I Tested These Changes `tox -e all` ## Changelog NOCHANGELOG
- Loading branch information