def METHOD_NAME(tmpdir, cwd_tmpdir, tmp_repo, capsys):
    """Jupytext refuses to sync two inconsistent notebooks"""
    write(new_notebook(cells=[new_markdown_cell("A short py notebook")]), "test.py")
    write(
        new_notebook(
            cells=[new_markdown_cell("Another ipynb notebook")],
            metadata={"jupytext": {"formats": "ipynb,py"}},
        ),
        "test.ipynb",
    )
    # Add them both
    tmp_repo.git.add("test.py")
    tmp_repo.git.add("test.ipynb")
    # Run jupytext
    status = jupytext(["--sync", "--pre-commit-mode", "test.ipynb"])
    # The diff should be visible
    assert status == 1
    out = capsys.readouterr()
    assert (
        """--- test.py