def METHOD_NAME(mocked_func, caplog):
    """Test for correct error format.
    Ensure a tokenization error returns the original one line json string
    w/o color and the log reflects the critical error.
    :param mocked_func: Mocked fixture
    :param caplog: Capture log
    """
    mocked_func.side_effect = ValueError()
    sample = serialize(**SAMPLE_JSON)
    _result = Colorize(grammar_dir=GRAMMAR_DIR, theme_path=THEME_PATH).render(
        doc=sample,
        scope="source.json",
    )
    assert "rendered without color" in caplog.text