gabriel / muse public
test guard dev
AI Agent gabriel · 159 days ago · Apr 19, 2026 · Diff

test(guard): seven-tier coverage for require_clean_workdir — unit, integration, e2e, stress, data integrity, security, performance

sha256:ba3752716fbcce2b7b7617bc080f4853e1e84d8f869777b879d3e7f7521598b9 sha
+56 symbols
sha256:d37ddd64fd70a8b8b5c070a099772a1add1be8b70981ea1642f76fc20a658448 snapshot
+56
symbols added
0
dead code introduced
Semantic Changes 56 symbols
~ tests/test_guard_supercharge.py .py 56 symbols added
+ TestDataIntegrity class class TestDataIntegrity L379–449
+ test_json_files_list_contains_actual_dirty_path method method test_json_files_list_contains_actual_dirty_path L380–389
+ test_json_files_list_sorted method method test_json_files_list_sorted L391–405
+ test_target_manifest_only_blocks_differing_files method method test_target_manifest_only_blocks_differing_files L407–436
+ test_untracked_files_not_in_json_files_list method method test_untracked_files_not_in_json_files_list L438–449
+ TestEndToEnd class class TestEndToEnd L260–316
+ test_checkout_allowed_when_target_does_not_change_dirty_file method method test_checkout_allowed_when_target_does_not_change_dirty_file L297–316
+ test_checkout_blocked_when_target_changes_dirty_file method method test_checkout_blocked_when_target_changes_dirty_file L277–295
+ test_reset_hard_blocked_by_dirty_workdir method method test_reset_hard_blocked_by_dirty_workdir L261–266
+ test_reset_hard_force_bypasses_guard method method test_reset_hard_force_bypasses_guard L268–275
+ TestIntegration class class TestIntegration L138–252
+ test_json_fmt_error_goes_to_stdout method method test_json_fmt_error_goes_to_stdout L158–165
+ test_json_fmt_includes_files_list method method test_json_fmt_includes_files_list L167–175
+ test_json_fmt_includes_hint method method test_json_fmt_includes_hint L185–192
+ test_json_fmt_includes_operation method method test_json_fmt_includes_operation L177–183
+ test_target_manifest_different_oid_blocks method method test_target_manifest_different_oid_blocks L213–224
+ test_target_manifest_file_deleted_in_target_blocks method method test_target_manifest_file_deleted_in_target_blocks L226–234
+ test_target_manifest_same_oid_carries_through method method test_target_manifest_same_oid_carries_through L194–211
+ test_text_fmt_error_goes_to_stderr method method test_text_fmt_error_goes_to_stderr L149–156
+ test_text_fmt_error_message_mentions_operation method method test_text_fmt_error_message_mentions_operation L139–147
+ test_truncation_at_ten_files method method test_truncation_at_ten_files L236–252
+ TestPerformance class class TestPerformance L506–524
+ test_clean_repo_check_under_2s method method test_clean_repo_check_under_2s L507–513
+ test_dirty_repo_check_under_2s method method test_dirty_repo_check_under_2s L515–524
+ TestSecurity class class TestSecurity L457–498
+ test_ansi_in_operation_not_echoed_raw method method test_ansi_in_operation_not_echoed_raw L458–466
+ test_ansi_in_operation_not_in_json_output method method test_ansi_in_operation_not_in_json_output L490–498
+ test_json_output_is_valid_json_with_special_chars_in_operation method method test_json_output_is_valid_json_with_special_chars_in_operation L477–488
+ test_null_byte_in_operation_does_not_crash method method test_null_byte_in_operation_does_not_crash L468–474
+ TestStress class class TestStress L324–371
+ test_500_dirty_files_raises_and_truncates method method test_500_dirty_files_raises_and_truncates L325–339
+ test_concurrent_calls_same_repo_all_raise method method test_concurrent_calls_same_repo_all_raise L341–363
+ test_repeated_calls_clean_repo_never_raise method method test_repeated_calls_clean_repo_never_raise L365–371
+ TestUnit class class TestUnit L83–130
+ test_added_untracked_file_does_not_raise method method test_added_untracked_file_does_not_raise L112–117
+ test_clean_workdir_does_not_raise method method test_clean_workdir_does_not_raise L90–93
+ test_deleted_tracked_file_raises method method test_deleted_tracked_file_raises L103–110
+ test_empty_repo_no_commits_does_not_raise method method test_empty_repo_no_commits_does_not_raise L119–124
+ test_force_false_default_is_checked method method test_force_false_default_is_checked L126–130
+ test_force_true_is_noop method method test_force_true_is_noop L84–88
+ test_modified_tracked_file_raises method method test_modified_tracked_file_raises L95–101
+ _commit function function _commit L52–59
+ _init_repo function function _init_repo L43–49
+ _invoke function function _invoke L34–40
+ clean_repo function function clean_repo L63–68
+ dirty_repo function function dirty_repo L72–75
+ CliRunner import import CliRunner L24–24
+ InvokeResult import import InvokeResult L24–24
+ annotations import import annotations L14–14
+ json import import json L16–16
+ os import import os L17–17
+ pathlib import import pathlib L18–18
+ pytest import import pytest L22–22
+ threading import import threading L19–19
+ time import import time L20–20
+ runner variable variable runner L26–26
← Older Oldest on dev
All commits
Newer → Latest on dev

0 comments

No comments yet. Be the first to start the discussion.

To add a comment, use the Muse CLI: muse hub commit comment sha256:ba3752716fbcce2b7b7617bc080f4853e1e84d8f869777b879d3e7f7521598b9 --body "your comment"