(self)
| 718 | |
| 719 | @pytest.mark.integration |
| 720 | def test_offline_dataset_module_factory(self): |
| 721 | repo_id = SAMPLE_DATASET_IDENTIFIER2 |
| 722 | builder = load_dataset_builder(repo_id, cache_dir=self.cache_dir) |
| 723 | builder.download_and_prepare() |
| 724 | for offline_simulation_mode in list(OfflineSimulationMode): |
| 725 | with offline(offline_simulation_mode): |
| 726 | self._caplog.clear() |
| 727 | # allow provide the repo id without an explicit path to remote or local actual file |
| 728 | dataset_module = datasets.load.dataset_module_factory(repo_id, cache_dir=self.cache_dir) |
| 729 | self.assertEqual(dataset_module.module_path, "datasets.packaged_modules.cache.cache") |
| 730 | self.assertIn("Using the latest cached version of the dataset", self._caplog.text) |
| 731 | |
| 732 | @pytest.mark.integration |
| 733 | def test_offline_dataset_module_factory_with_capital_letters_in_name(self): |
nothing calls this directly
no test coverage detected