Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Tests for PR#528 #534

Closed

Conversation

sentry-autofix[bot]
Copy link

This PR adds tests for #528

Commits:

  • Add unit tests for network_upload command
  • Update CLI command list test to include network-upload

…sts/commands/` directory. The file contains unit tests for the `network_upload` command. Here's a breakdown of the tests:

1. We import necessary modules and mock the `NetworkFinder` and `UploadSender` classes.
2. We create test fixtures for the mocked classes.
3. We define four test functions:
   a. `test_network_upload_dry_run`: Tests the dry run functionality.
   b. `test_network_upload_success`: Tests a successful network upload.
   c. `test_network_upload_failure`: Tests a failed network upload.
   d. `test_network_upload_no_files_found`: Tests the case when no files are found in the network.

Each test function uses the `CliRunner` to invoke the `network_upload` command with various arguments and checks the output and behavior of the command.
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.

1 participant