diff --git a/.circleci/create_circleci_config.py b/.circleci/create_circleci_config.py index d8d3e7d86cf..7ccf5ec96ce 100644 --- a/.circleci/create_circleci_config.py +++ b/.circleci/create_circleci_config.py @@ -312,6 +312,15 @@ repo_utils_job = CircleCIJob( ) +non_model_job = CircleCIJob( + "non_model", + docker_image=[{"image": "huggingface/transformers-torch-light"}], + marker="not generate", + parallelism=6, + pytest_num_workers=8, +) + + # We also include a `dummy.py` file in the files to be doc-tested to prevent edge case failure. Otherwise, the pytest # hangs forever during test collection while showing `collecting 0 items / 21 errors`. (To see this, we have to remove # the bash output redirection.) @@ -336,7 +345,7 @@ doc_test_job = CircleCIJob( pytest_num_workers=1, ) -REGULAR_TESTS = [torch_and_tf_job, torch_and_flax_job, torch_job, tf_job, flax_job, hub_job, onnx_job, tokenization_job, processor_job, generate_job] # fmt: skip +REGULAR_TESTS = [torch_and_tf_job, torch_and_flax_job, torch_job, tf_job, flax_job, hub_job, onnx_job, tokenization_job, processor_job, generate_job, non_model_job] # fmt: skip EXAMPLES_TESTS = [examples_torch_job, examples_tensorflow_job] PIPELINE_TESTS = [pipelines_torch_job, pipelines_tf_job] REPO_UTIL_TESTS = [repo_utils_job] diff --git a/tests/generation/test_configuration_utils.py b/tests/generation/test_configuration_utils.py index 1e11a9679b2..9c7f4db3c92 100644 --- a/tests/generation/test_configuration_utils.py +++ b/tests/generation/test_configuration_utils.py @@ -114,6 +114,10 @@ class GenerationConfigTest(unittest.TestCase): # `.update()` returns a dictionary of unused kwargs self.assertEqual(unused_kwargs, {"foo": "bar"}) + # TODO: @Arthur and/or @Joao + # FAILED tests/generation/test_configuration_utils.py::GenerationConfigTest::test_initialize_new_kwargs - AttributeError: 'GenerationConfig' object has no attribute 'get_text_config' + # See: https://app.circleci.com/pipelines/github/huggingface/transformers/104831/workflows/e5e61514-51b7-4c8c-bba7-3c4d2986956e/jobs/1394252 + @unittest.skip("failed with `'GenerationConfig' object has no attribute 'get_text_config'`") def test_initialize_new_kwargs(self): generation_config = GenerationConfig() generation_config.foo = "bar" diff --git a/tests/utils/test_import_structure.py b/tests/utils/test_import_structure.py index 18f4b840088..0a9bf38fa40 100644 --- a/tests/utils/test_import_structure.py +++ b/tests/utils/test_import_structure.py @@ -36,6 +36,9 @@ class TestImportStructures(unittest.TestCase): models_path = base_transformers_path / "src" / "transformers" / "models" models_import_structure = spread_import_structure(define_import_structure(models_path)) + # TODO: Lysandre + # See https://app.circleci.com/pipelines/github/huggingface/transformers/104762/workflows/7ba9c6f7-a3b2-44e6-8eaf-749c7b7261f7/jobs/1393260/tests + @unittest.skip(reason="failing") def test_definition(self): import_structure = define_import_structure(import_structures) import_structure_definition = { @@ -93,6 +96,9 @@ class TestImportStructures(unittest.TestCase): ) self.assertListEqual(sorted(objects), sorted(_all), msg=error_message) + # TODO: Lysandre + # See https://app.circleci.com/pipelines/github/huggingface/transformers/104762/workflows/7ba9c6f7-a3b2-44e6-8eaf-749c7b7261f7/jobs/1393260/tests + @unittest.skip(reason="failing") def test_export_backend_should_be_defined(self): with self.assertRaisesRegex(ValueError, "Backend should be defined in the BACKENDS_MAPPING"): pass diff --git a/utils/tests_fetcher.py b/utils/tests_fetcher.py index 1aa663e967c..b8408f9d453 100644 --- a/utils/tests_fetcher.py +++ b/utils/tests_fetcher.py @@ -1148,6 +1148,7 @@ JOB_TO_TEST_FILE = { "pipelines_torch": r"tests/models/.*/test_modeling_(?!(?:flax_|tf_)).*", "tests_hub": r"tests/.*", "tests_onnx": r"tests/models/.*/test_modeling_(?:tf_|(?!flax)).*", + "tests_non_model": r"tests/[^/]*?/test_.*\.py", }