@@ -418,24 +418,28 @@ def setUp(self):
418418 )
419419
420420 def test_HubDatasetModuleFactoryWithScript_dont_trust_remote_code (self ):
421- # "lhoestq/test" has a dataset script
422421 factory = HubDatasetModuleFactoryWithScript (
423- "lhoestq/test" , download_config = self .download_config , dynamic_modules_path = self .dynamic_modules_path
422+ "hf-internal-testing/dataset_with_script" ,
423+ download_config = self .download_config ,
424+ dynamic_modules_path = self .dynamic_modules_path ,
424425 )
425426 with patch .object (config , "HF_DATASETS_TRUST_REMOTE_CODE" , None ): # this will be the default soon
426427 self .assertRaises (ValueError , factory .get_module )
427428 factory = HubDatasetModuleFactoryWithScript (
428- "lhoestq/test " ,
429+ "hf-internal-testing/dataset_with_script " ,
429430 download_config = self .download_config ,
430431 dynamic_modules_path = self .dynamic_modules_path ,
431432 trust_remote_code = False ,
432433 )
433434 self .assertRaises (ValueError , factory .get_module )
434435
435- def test_HubDatasetModuleFactoryWithScript_with_github_dataset (self ):
436+ def test_HubDatasetModuleFactoryWithScript_with_hub_dataset (self ):
436437 # "wmt_t2t" has additional imports (internal)
437438 factory = HubDatasetModuleFactoryWithScript (
438- "wmt_t2t" , download_config = self .download_config , dynamic_modules_path = self .dynamic_modules_path
439+ "wmt_t2t" ,
440+ download_config = self .download_config ,
441+ dynamic_modules_path = self .dynamic_modules_path ,
442+ revision = "861aac88b2c6247dd93ade8b1c189ce714627750" ,
439443 )
440444 module_factory_result = factory .get_module ()
441445 assert importlib .import_module (module_factory_result .module_path ) is not None
0 commit comments