mirror of
https://github.com/codeflash-ai/codeflash.git
synced 2026-05-04 18:25:17 +00:00
fix: remove test for deleted create_pyproject_toml function
The function was removed in the dead code cleanup but the test file still imported it and had a TestCreatePyprojectToml class, causing ImportError. Co-authored-by: Kevin Turcios <undefined@users.noreply.github.com> Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
d1a128dcda
commit
8dc6d9eeda
1 changed files with 0 additions and 24 deletions
|
|
@ -8,7 +8,6 @@ from codeflash.setup.config_schema import CodeflashConfig
|
|||
from codeflash.setup.config_writer import (
|
||||
_write_package_json,
|
||||
_write_pyproject_toml,
|
||||
create_pyproject_toml,
|
||||
remove_config,
|
||||
write_config,
|
||||
)
|
||||
|
|
@ -339,26 +338,3 @@ class TestRemoveConfig:
|
|||
data = json.load(f)
|
||||
assert data["name"] == "test" # Preserved
|
||||
assert "codeflash" not in data
|
||||
|
||||
|
||||
class TestCreatePyprojectToml:
|
||||
"""Tests for create_pyproject_toml function."""
|
||||
|
||||
def test_creates_minimal_pyproject(self, tmp_path):
|
||||
"""Should create minimal pyproject.toml."""
|
||||
success, message = create_pyproject_toml(tmp_path)
|
||||
|
||||
assert success is True
|
||||
assert (tmp_path / "pyproject.toml").exists()
|
||||
|
||||
content = (tmp_path / "pyproject.toml").read_text()
|
||||
assert "codeflash" in content.lower()
|
||||
|
||||
def test_fails_if_already_exists(self, tmp_path):
|
||||
"""Should fail if pyproject.toml already exists."""
|
||||
(tmp_path / "pyproject.toml").write_text('[project]\nname = "test"')
|
||||
|
||||
success, message = create_pyproject_toml(tmp_path)
|
||||
|
||||
assert success is False
|
||||
assert message == f"pyproject.toml already exists at {tmp_path / 'pyproject.toml'}"
|
||||
|
|
|
|||
Loading…
Reference in a new issue