DataDog / datadog-ci-rb

Ruby library for Datadog test visibility
https://docs.datadoghq.com/continuous_integration/tests/ruby
Other
8 stars 4 forks source link

[CIVIS-2938] Upload packfiles API client #153

Closed anmarchenko closed 6 months ago

anmarchenko commented 6 months ago

What does this PR do? Adds Git::UploadPackfile class that is able to upload a single git packfile to Datadog's git API.

Makes minor changes to git_commits_rev_list and git_generate_packfiles methods to make them safer and prevent shell injections.

How to test the change? Unit tests are provided, otherwise this functionality is not used yet

codecov-commenter commented 6 months ago

Codecov Report

Attention: Patch coverage is 98.87640% with 1 line in your changes missing coverage. Please review.

Project coverage is 99.02%. Comparing base (e238a74) to head (40cd927).

Files with missing lines Patch % Lines
spec/datadog/ci/git/upload_packfile_spec.rb 97.50% 1 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## 1.0 #153 +/- ## ========================================== - Coverage 99.05% 99.02% -0.03% ========================================== Files 184 186 +2 Lines 8341 8421 +80 Branches 346 352 +6 ========================================== + Hits 8262 8339 +77 - Misses 79 82 +3 ```

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