Add options for condensing/expanding output when using "text" format

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

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

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
25/100
Loại issue
Tính năng
Độ rõ ràng
Cần làm rõ
Mức độ hoạt động
Đình trệ
Công nghệ
go
Lĩnh vực
cli, testing

Hướng nghiên cứu

Bắt đầu bằng cách xác định phần triển khai của định dạng đầu ra "text" hiện tại và xem xét cách các kết quả kiểm thử được hiển thị. Xác định các mức độ chi tiết được hỗ trợ và đầu ra mong đợi của chúng bằng các ví dụ Standard, Compact, Quiet và có thể là verbose trong issue; được coi là hoàn thành khi tùy chọn được chọn luôn tạo ra định dạng đã thống nhất.

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

Mô tả

When using CST in a CI/CD environment, it would be nice to have multiple options for verbosity of results output. The current "text" format output is informative but noisy in passing cases. Sometimes a "pass-quiet, fail-noisy" option would be nice to have.

I'm still thinking about these, and am certainly open to suggestion, but as conversation starters...I could imagine a few levels of verbosity:

Standard (the current output):


=========================================
====== Test file: example-cst.yaml ======
=========================================
=== RUN: File Existence Test: whoami
--- PASS
duration: 0s
=== RUN: File Existence Test: whatami
--- FAIL
duration: 0s
Error: Error examining file in container: Error retrieving file from container: API error (404): Could not find the file /usr/bin/whatami in container 291dffd038c6843ff4e11bfda3f0cbe075e253b9e0756c94359e18137a564ba0
=== RUN: Metadata Test
--- PASS
duration: 0s

=========================================
================ RESULTS ================
=========================================
Passes:      2
Failures:    1
Duration:    0s
Total tests: 3

FAIL

Compact:

====== Test file: example-cst.yaml ======
.F.

Failures:
File Existence Test: whatami
Error: Error examining file in container: Error retrieving file from container: API error (404): Could not find the file /usr/bin/whatami in container 291dffd038c6843ff4e11bfda3f0cbe075e253b9e0756c94359e18137a564ba0

Passes:      2
Failures:    1
Duration:    0s
Total tests: 3

FAIL

Quiet:

====== Test file: example-cst.yaml ======
Passes:      2
Failures:    1
Duration:    0s
Total tests: 3

FAIL

...and maybe one called "verbose" or "debug" or similar that actually adds info to the current output...like echoing each command run?

Ngôn ngữ chính
Go
Star
2.5k
Fork
213
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

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 GoogleContainerTools/container-structure-test

Tất cả issue của GoogleContainerTools/container-structure-test

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.