test(scp): the sftp upload and download paths have no tests

Đang mở
#956 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 3 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
78/100
Loại issue
Tính năng
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
go
Lĩnh vực
testing

Hướng nghiên cứu

Read cmd/cli/scp/scp_test.go and the four copy functions named in the issue. Add a round-trip test using an in-process sftp.NewServer over an in-memory pipe, covering file and directory transfers in both directions; verify the copied contents so silent truncation fails the test.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

cmd/cli/scp/scp_test.go tests only parsePath. No test calls copyFileToRemote, copyDirToRemote, copyFileFromRemote or copyDirFromRemote, so the #944 sftp bump (1.13.11 to 1.13.12) shipped with no coverage on the code it affects. In the #944 review, mutants planted in the vendored sftp client survived the whole suite.

Acceptance: a round-trip test against an in-process sftp.NewServer over an in-memory pipe, covering a file and a directory in each direction, that fails when a copy silently truncates.

Ngôn ngữ chính
Go
Star
31
Fork
20
Merge trung bình
2 ngày 4 giờ
Pull request đã merge (30 ngày)
11

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của NVIDIA/holodeck

Tất cả issue của NVIDIA/holodeck

Issue tương tự

Thêm issue về Go

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.