@@ -406,7 +406,6 @@ def test__download_minio_file_works_with_bucket_subdirectory(self):
406406 file_destination
407407 ), "_download_minio_file can download from subdirectories"
408408
409-
410409 @mock .patch ("openml._api_calls._download_minio_file" )
411410 @pytest .mark .test_server ()
412411 def test__get_dataset_parquet_is_cached (self , patch ):
@@ -530,7 +529,10 @@ def test_deletion_of_cache_dir_faulty_download(self, patch):
530529 datasets_cache_dir = os .path .join (openml .config .get_cache_directory (), "datasets" )
531530 assert len (os .listdir (datasets_cache_dir )) == 0
532531
533- @pytest .mark .skip (reason = "Pending resolution of #1657" )
532+ @pytest .mark .skipif (
533+ os .getenv ("OPENML_USE_LOCAL_SERVICES" ) == "true" ,
534+ reason = "Pending resolution of #1657" ,
535+ )
534536 @pytest .mark .test_server ()
535537 def test_publish_dataset (self ):
536538 arff_file_path = self .static_cache_dir / "org" / "openml" / "test" / "datasets" / "2" / "dataset.arff"
@@ -690,7 +692,10 @@ def test_attributes_arff_from_df_unknown_dtype(self):
690692 with pytest .raises (ValueError , match = err_msg ):
691693 attributes_arff_from_df (df )
692694
693- @pytest .mark .skip (reason = "Pending resolution of #1657" )
695+ @pytest .mark .skipif (
696+ os .getenv ("OPENML_USE_LOCAL_SERVICES" ) == "true" ,
697+ reason = "Pending resolution of #1657" ,
698+ )
694699 @pytest .mark .test_server ()
695700 def test_create_dataset_numpy (self ):
696701 data = np .array ([[1 , 2 , 3 ], [1.2 , 2.5 , 3.8 ], [2 , 5 , 8 ], [0 , 1 , 0 ]]).T
@@ -725,7 +730,10 @@ def test_create_dataset_numpy(self):
725730 ), "Uploaded arff does not match original one"
726731 assert _get_online_dataset_format (dataset .id ) == "arff" , "Wrong format for dataset"
727732
728- @pytest .mark .skip (reason = "Pending resolution of #1657" )
733+ @pytest .mark .skipif (
734+ os .getenv ("OPENML_USE_LOCAL_SERVICES" ) == "true" ,
735+ reason = "Pending resolution of #1657" ,
736+ )
729737 @pytest .mark .test_server ()
730738 def test_create_dataset_list (self ):
731739 data = [
@@ -781,7 +789,10 @@ def test_create_dataset_list(self):
781789 ), "Uploaded ARFF does not match original one"
782790 assert _get_online_dataset_format (dataset .id ) == "arff" , "Wrong format for dataset"
783791
784- @pytest .mark .skip (reason = "Pending resolution of #1657" )
792+ @pytest .mark .skipif (
793+ os .getenv ("OPENML_USE_LOCAL_SERVICES" ) == "true" ,
794+ reason = "Pending resolution of #1657" ,
795+ )
785796 @pytest .mark .test_server ()
786797 def test_create_dataset_sparse (self ):
787798 # test the scipy.sparse.coo_matrix
@@ -930,7 +941,10 @@ def test_get_online_dataset_format(self):
930941 dataset_id
931942 ), "The format of the ARFF files is different"
932943
933- @pytest .mark .skip (reason = "Pending resolution of #1657" )
944+ @pytest .mark .skipif (
945+ os .getenv ("OPENML_USE_LOCAL_SERVICES" ) == "true" ,
946+ reason = "Pending resolution of #1657" ,
947+ )
934948 @pytest .mark .test_server ()
935949 def test_create_dataset_pandas (self ):
936950 data = [
@@ -1156,7 +1170,10 @@ def test_ignore_attributes_dataset(self):
11561170 paper_url = paper_url ,
11571171 )
11581172
1159- @pytest .mark .skip (reason = "Pending resolution of #1657" )
1173+ @pytest .mark .skipif (
1174+ os .getenv ("OPENML_USE_LOCAL_SERVICES" ) == "true" ,
1175+ reason = "Pending resolution of #1657" ,
1176+ )
11601177 @pytest .mark .test_server ()
11611178 def test_publish_fetch_ignore_attribute (self ):
11621179 """Test to upload and retrieve dataset and check ignore_attributes"""
@@ -1276,7 +1293,10 @@ def test_create_dataset_row_id_attribute_error(self):
12761293 paper_url = paper_url ,
12771294 )
12781295
1279- @pytest .mark .skip (reason = "Pending resolution of #1657" )
1296+ @pytest .mark .skipif (
1297+ os .getenv ("OPENML_USE_LOCAL_SERVICES" ) == "true" ,
1298+ reason = "Pending resolution of #1657" ,
1299+ )
12801300 @pytest .mark .test_server ()
12811301 def test_create_dataset_row_id_attribute_inference (self ):
12821302 # meta-information
@@ -1445,7 +1465,10 @@ def test_data_edit_non_critical_field(self):
14451465 edited_dataset = openml .datasets .get_dataset (did )
14461466 assert edited_dataset .description == desc
14471467
1448- @pytest .mark .skip (reason = "Pending resolution of #1657" )
1468+ @pytest .mark .skipif (
1469+ os .getenv ("OPENML_USE_LOCAL_SERVICES" ) == "true" ,
1470+ reason = "Pending resolution of #1657" ,
1471+ )
14491472 @pytest .mark .test_server ()
14501473 def test_data_edit_critical_field (self ):
14511474 # Case 2
@@ -1498,7 +1521,10 @@ def test_data_edit_requires_valid_dataset(self):
14981521 description = "xor operation dataset" ,
14991522 )
15001523
1501- @pytest .mark .skip (reason = "Pending resolution of #1657" )
1524+ @pytest .mark .skipif (
1525+ os .getenv ("OPENML_USE_LOCAL_SERVICES" ) == "true" ,
1526+ reason = "Pending resolution of #1657" ,
1527+ )
15021528 @pytest .mark .test_server ()
15031529 def test_data_edit_cannot_edit_critical_field_if_dataset_has_task (self ):
15041530 # Need to own a dataset to be able to edit meta-data
@@ -1551,7 +1577,6 @@ def test_data_fork(self):
15511577 data_id = 999999 ,
15521578 )
15531579
1554-
15551580 @pytest .mark .production_server ()
15561581 def test_list_datasets_with_high_size_parameter (self ):
15571582 # Testing on prod since concurrent deletion of uploded datasets make the test fail
0 commit comments