MCPcopy
hub / github.com/aiming-lab/AutoResearchClaw / test_resolve_ours

Method test_resolve_ours

tests/test_overleaf.py:56–73  ·  view source on GitHub ↗
(self, tmp_path: Path)

Source from the content-addressed store, hash-verified

54 assert conflicts[0]["theirs"] == "line B"
55
56 def test_resolve_ours(self, tmp_path: Path) -> None:
57 content = textwrap.dedent("""\
58 \\section{Intro}
59 <<<<<<< HEAD
60 AI version
61 =======
62 Human version
63 >>>>>>> remote
64 \\section{End}
65 """)
66 (tmp_path / "paper.tex").write_text(content)
67 resolver = ConflictResolver()
68 resolved = resolver.resolve(tmp_path, strategy="ours")
69 assert len(resolved) == 1
70 text = (tmp_path / "paper.tex").read_text()
71 assert "AI version" in text
72 assert "Human version" not in text
73 assert "<<<<<<" not in text
74
75 def test_resolve_theirs(self, tmp_path: Path) -> None:
76 content = textwrap.dedent("""\

Callers

nothing calls this directly

Calls 2

resolveMethod · 0.95
ConflictResolverClass · 0.90

Tested by

no test coverage detected