Draft
Conversation
austin-aryn-ai
commented
Jun 22, 2025
Comment on lines
+36
to
+41
| @pytest.fixture(scope="function", autouse=True) | ||
| def check_huggingface_hub(request): | ||
| """ | ||
| Use this to find tests that download a model from Huggingface. | ||
| """ | ||
|
|
Contributor
Author
There was a problem hiding this comment.
This hook won't be enabled in main.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I used the pytest hook in this PR to find all unit tests that download a model from Huggingface:
test_infer
test_partition
test_partition_with_ocr_instance
test_table_extraction_order
test_detr_pdfminer_object_type
test_sentence_transformer[sentence-transformers/all-MiniLM-L6-v2-384-texts0]
test_sentence_transformer[sentence-transformers/all-MiniLM-L6-v2-384-texts1]
test_sentence_transformer[sentence-transformers/all-mpnet-base-v2-768-texts2]
test_sentence_transformer_embedding
test_sentence_transformer_batch_size
test_merge_elements
test_merge_elements_via_execute
test_docset_greedy
test_merge_elements
test_merge_elements_image_summarize
test_merge_elements_via_execute
test_docset_greedy
test_merge_empty_text_works
test_merge_elements
test_merge_elements_via_execute
test_docset_augmented
test_transformers_similarity_scorer
test_transformers_similarity_scorer_no_doc_structure
test_transformers_similarity_scorer_no_element_id
test_transformers_score_similarity
test_split_elements
test_via_execute
test_tf_with_bert_tokenizer
test_tf_with_bert_tokenizer_with_token_ids
I think some of these can be rewritten not to use a model from HF and some of them should be moved to /integration.