def METHOD_NAME(monkeypatch, caplog, samples_path):
    try:
        monkeypatch.delattr(haystack.nodes.file_classifier.file_type, "magic")
    except AttributeError:
        # magic not installed, even better
        pass
    node = FileTypeClassifier(supported_types=[""])
    with caplog.at_level(logging.ERROR):
        node.run(samples_path / "extensionless_files" / f"pdf_file")
        assert "'python-magic' is not installed" in caplog.text