test: expand coverage for git, filesystem, base_service, and http_client#10
Merged
Merged
Conversation
Fill coverage gaps in the weakest units identified by a baseline run (git.rb 60%, base_service.rb 52%, filesystem.rb 48%): - git_spec: init/remote_add/remote_get, branch ops, add/commit/reset/restore, push & pull with credentials (incl. URL restore on failure), config helpers, dangerously_authenticate, GitStatus predicates, rename/unmerged parsing - envd_http_client_spec: handle_rpc_response envelope decoding, with_retry idempotent/non-idempotent/abort branches, resolve_proxy, handle_response, normalize_path - filesystem_spec: get_info/exists?/rename/make_dir/remove/write_files/aliases plus private extraction and upload-response parsing edge cases - base_service_spec: envd_client construction and no_proxy bypass - http_client_spec: post/put method bodies Suite: 279 -> 363 examples, 0 failures. Line coverage 81.61% -> 89.15%; branch 60.48% -> 70.92%. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Test-only change that fills coverage gaps in the units a baseline coverage run flagged as weakest —
git.rb(60.1%),base_service.rb(52.4%), andfilesystem.rb(48.2%) — plus quick wins inhttp_client.rb. No production code was touched.What was added
git_spec—init/remote_add/remote_get, branch ops,add/commit/reset/restore,push/pullwith credentials (including restoring the original remote URL even when the push fails), config helpers,dangerously_authenticate,GitStatuspredicates, andstatusparsing of rename/unmerged entries.envd_http_client_spec—handle_rpc_responseConnect-envelope stream decoding (incl. multibyte UTF-8 and unparseable frames),with_retryidempotent/non-idempotent/abort branches,resolve_proxy,handle_response,normalize_path.filesystem_spec—get_info/exists?/rename/make_dir/remove/write_files/aliases and the private extraction + upload-response parsing edge cases.base_service_spec—envd_clientconstruction andno_proxybypass.http_client_spec—post/putmethod bodies.Results
git.rbreached 99.3% line coverage. Fullrake specis green (0 failures) andrubocopreports no offenses across all 61 files.🤖 Generated with Claude Code