Skip to content

Conversation

@ArjunDixit1
Copy link
Contributor

Closes #38

This PR introduces a comprehensive suite of unit tests for the DownloadOrchestrator class, addressing the lack of test coverage for this critical component. The new tests verify its core functionality—including concurrency, error handling, and control methods—which will improve code reliability and make future changes safer to implement.

Key Changes

The new test suite (tests/core/test_download_orchestrator.py) covers the following scenarios:

Initialization: Verifies that the orchestrator is set up correctly with the specified concurrency limit.

execute_download Logic:

Tests the main success path ("happy path").

Handles failure scenarios like repository fetch errors.

Covers edge cases such as empty repositories and partial download failures.

_download_single_file Logic:

Tests the file skipping mechanism (overwrite_existing=False).

Verifies content saving and error handling during individual file downloads.

Control Methods: Ensures the cancel(), pause(), and resume() methods are functional.

How to Verify

Pull down this branch.

Install the development dependencies: pip install -e .[dev]

Run the full test suite and confirm that all tests pass:
image

@Einswilli
Copy link
Contributor

Seems tests failed for tests/core/test_download_orchestrator.py (is your repo up to date please???)

@ArjunDixit1
Copy link
Contributor Author

Seems tests failed for tests/core/test_download_orchestrator.py (is your repo up to date please???)

Yes Ill check again

@ArjunDixit1 ArjunDixit1 force-pushed the feat/add-orchestrator-unit-tests branch from 90a7f56 to d6e3412 Compare October 6, 2025 19:59
@ArjunDixit1
Copy link
Contributor Author

@Einswilli Its done

Copy link
Contributor

@Einswilli Einswilli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your Contributions boss

@Einswilli Einswilli merged commit 59777a4 into AllDotPy:master Oct 6, 2025
2 checks passed
@ArjunDixit1 ArjunDixit1 deleted the feat/add-orchestrator-unit-tests branch October 9, 2025 09:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add unit tests for DownloadOrchestrator

2 participants