oras-project / oras

OCI registry client - managing content like artifacts, images, packages
https://oras.land
Apache License 2.0
1.52k stars 181 forks source link

refactor: create an interface for status console #1481

Closed TerryHowe closed 2 months ago

TerryHowe commented 3 months ago

What this PR does / why we need it:

Create a interface for console so that alternate implementations can exist. In doing this, I found the Size() method was not properly implemented, so I created a GetHeightWidth() method.

Partial: https://github.com/oras-project/oras/issues/1461

codecov[bot] commented 3 months ago

Codecov Report

Attention: Patch coverage is 90.90909% with 2 lines in your changes missing coverage. Please review.

Project coverage is 86.05%. Comparing base (e0f4066) to head (83474e7). Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
...md/oras/internal/display/status/console/console.go 87.50% 1 Missing and 1 partial :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #1481 +/- ## ========================================== - Coverage 86.10% 86.05% -0.06% ========================================== Files 118 118 Lines 4224 4223 -1 ========================================== - Hits 3637 3634 -3 - Misses 350 351 +1 - Partials 237 238 +1 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.