Skip to content

added configurable scp put timeout. added tests#121

Open
TAlonglong wants to merge 5 commits intopytroll:mainfrom
TAlonglong:issue120-scpclient-timeout-config
Open

added configurable scp put timeout. added tests#121
TAlonglong wants to merge 5 commits intopytroll:mainfrom
TAlonglong:issue120-scpclient-timeout-config

Conversation

@TAlonglong
Copy link
Copy Markdown
Collaborator

Added configurable scpclient_timeout_seconds attribute to the scpclient put.

@TAlonglong TAlonglong requested review from mraspaud and pnuu as code owners June 17, 2022 11:42
@codecov
Copy link
Copy Markdown

codecov Bot commented Jun 17, 2022

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 76.74%. Comparing base (499cf2f) to head (570883d).
⚠️ Report is 447 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #121      +/-   ##
==========================================
+ Coverage   76.57%   76.74%   +0.17%     
==========================================
  Files          18       18              
  Lines        3893     3922      +29     
==========================================
+ Hits         2981     3010      +29     
  Misses        912      912              
Flag Coverage Δ
unittests 76.74% <100.00%> (+0.17%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@TAlonglong
Copy link
Copy Markdown
Collaborator Author

Not sure what the stickler issue is about. ELLIPSIS_MARKER is not used. Was it used in the past and not used anymore?

If you have time @pnuu

Copy link
Copy Markdown
Member

@pnuu pnuu left a comment

Choose a reason for hiding this comment

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

In principle LGTM, but couple of requests inline.

Comment thread trollmoves/movers.py

"""Movers for the move_it scripts."""

from doctest import ELLIPSIS_MARKER
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I don't see this in main at all, so don't know where it's coming from. Should be safe to remove.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Oh, actually, it's coming from this PR since it shows up in the diff.


@patch('trollmoves.movers.SSHClient', autospec=True)
@patch('trollmoves.movers.SCPClient', autospec=True)
def test_scp_copy_custom_timeout(self, mock_scp_client, mock_sshclient):
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

The timeout isn't tested in this test, so either adjust the name or test the timeout.

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 configurable timeout to SCPClient

2 participants