Skip to content

Commit cce97b3

Browse files
committed
Remove redundant tests for version bump without changes in test_core.py
1 parent a12cd55 commit cce97b3

1 file changed

Lines changed: 0 additions & 39 deletions

File tree

tests/test_core.py

Lines changed: 0 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,6 @@
3232
- test_process_file_read_error(mock_read, tmp_path: Path, capsys: pytest.CaptureFixture[str]) -> None (line 403)
3333
- test_process_file_write_error(mock_write, tmp_path: Path, capsys: pytest.CaptureFixture[str]) -> None (line 414)
3434
- test_process_file_parser_error(source_processor) -> None (line 425)
35-
- test_process_file_version_bump_no_changes(source_processor) -> None (line 430)
36-
- test_process_file_version_bump_no_changes_verbose(source_processor, capsys: pytest.CaptureFixture[str]) -> None (line 449)
3735
- TestDiscoverAndProcessFiles (line 468):
3836
- test_discover_single_directory(tmp_path: Path) -> None (line 471)
3937
- test_discover_multiple_directories(tmp_path: Path) -> None (line 486)
@@ -408,43 +406,6 @@ def test_process_file_parser_error(self, source_processor) -> None:
408406
# It should not crash
409407
source_processor("malformed.py", "def func(a,:", verbose=True)
410408

411-
def test_process_file_version_bump_no_changes(self, source_processor) -> None:
412-
"""Test that version bump in header without code changes updates the docstring to current version."""
413-
content = '''"""
414-
--- AUTO-GENERATED DOCSTRING ---
415-
This docstring is automatically generated by Agent Docstrings v1.2.0
416-
Do not modify this block directly.
417-
418-
Classes/Functions:
419-
- foo() (line 1)
420-
--- END AUTO-GENERATED DOCSTRING ---
421-
"""
422-
def foo():
423-
pass'''
424-
processed_content, _, _ = source_processor("test.py", content, verbose=False)
425-
# The header version should be updated to the current version
426-
assert "generated by Agent Docstrings v" in processed_content
427-
assert "v1.3.0" in processed_content
428-
assert "v1.2.0" not in processed_content
429-
430-
def test_process_file_version_bump_no_changes_verbose(self, source_processor, capsys: pytest.CaptureFixture[str]) -> None:
431-
"""Test that version-only header changes produce a processed message when verbose."""
432-
content = '''"""
433-
--- AUTO-GENERATED DOCSTRING ---
434-
This docstring is automatically generated by Agent Docstrings v1.2.0
435-
Do not modify this block directly.
436-
437-
Classes/Functions:
438-
- foo() (line 1)
439-
--- END AUTO-GENERATED DOCSTRING ---
440-
"""
441-
def foo():
442-
pass'''
443-
source_processor("test.py", content, verbose=True)
444-
captured = capsys.readouterr()
445-
# Should indicate that the file was processed
446-
assert "Processed Python:" in captured.out
447-
448409

449410
class TestDiscoverAndProcessFiles:
450411
"""Tests for discover_and_process_files function."""

0 commit comments

Comments
 (0)