Fix test fixture, README provenance and remaining Windows-only polish

Đang mở Phù hợp với người mới
#13 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

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

Đánh giá

Độ khó
2/5
Thời gian dự kiến
1-3 giờ
Mức phù hợp với người mới
62/100
Loại issue
Lỗi
Độ 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
devtools

Hướng nghiên cứu

Bắt đầu từ fixture TestCompareWindowsOnly trong plugin/scripts/godebugdiff_test.go, nơi winreadlinkvolume được kỳ vọng là Changed: 26 nhưng lẽ ra phải là 23. Tái hiện mục 1 bằng cách comment dòng c.WindowsOnly = isWindowsOnly(k) trong compare() và kiểm tra URL trong thông báo lỗi. Hoàn thành khi fixture khẳng định 23 với URL #go-123 và kiểm tra Before, After và Package, và examples/README.md nêu toolchain của từng tệp ở một chỗ duy nhất.

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

Mô tả

Follow-up from #12:

  1. TestCompareWindowsOnly (plugin/scripts/godebugdiff_test.go) gives winreadlinkvolume Changed: 26. The real value is 23, so the change gets the URL go.dev/doc/godebug#go-126 instead of #go-123. To reproduce: comment out c.WindowsOnly = isWindowsOnly(k) in compare() and run the test; the failure message prints URL:https://go.dev/doc/godebug#go-126. Use 23. The test also ignores the second value compare() returns and never checks Before, After or Package. Asserting them costs nothing.
  2. The WindowsOnly field comment now says "Windows-specific setting", but isWindowsOnly only checks the "win" name prefix. Make the comment match the rule, or derive the mark from an explicit list.
  3. examples/README.md line 12 still says the real outputs were made with Go 1.27.3, and the new line 24 says cobra.txt was redone with Go 1.27.4. Put the toolchain for each file in one place, for example a column in the table.
  4. Item 3 of #11 is still open, although #12 closes #11: the "No binary imports the package, so no effect" section still adds "(Windows only)". To reproduce: run from 1.22 to 1.23 on a module whose only binary is an empty func main() {}. Also, windowsOnly still uses omitempty while goCommand is always emitted, and the report does not tell Linux-only services that they can ignore the pins for Windows-only settings.

GillMacedo

Ngôn ngữ chính
Go
Star
0
Fork
3
Merge trung bình
4 giờ 55 phút
Pull request đã merge (30 ngày)
4

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

Mở trong Codespaces

Khởi chạy dev container của dự án ngay trên trình duyệt, bằng tài khoản GitHub của bạn.

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 GillMacedo/godebugdiff

Tất cả issue của GillMacedo/godebugdiff

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.