def METHOD_NAME(mock_tools):
    """If the version of flatpak-builder is old, an error is raised."""
    # Mock the side effect of a call to a missing flatpak-builder
    mock_tools.subprocess.check_output.side_effect = [
        "Flatpak 1.12.7",
        "flatpak-builder 0.10.9",
    ]
    with pytest.raises(
        BriefcaseCommandError,
        match=r"Briefcase requires flatpak-builder 1.0 or later.",
    ):
        Flatpak.verify(mock_tools)
    mock_tools.subprocess.check_output.assert_has_calls(
        [
            mock.call(["flatpak", "--version"]),
            mock.call(["flatpak-builder", "--version"]),
        ],
        any_order=False,
    )