def METHOD_NAME(same_attachments_plan):
    """
    Test running a Testplan that stores the same attachment multiple times.
    The file only needs to be stored once under the attachments but
    can be referenced from multiple parts of the report.
    """
    plan_result = same_attachments_plan.run()
    assert plan_result  # Plan should pass.
    report = plan_result.report
    attachments = report.attachments
    assert len(attachments) == 1  # Only one unique file is attached.
    attachment_entries = report.entries[0].entries[0].entries[0].entries
    assert len(attachment_entries) == 2
    dst_path = list(attachments.keys())[0]
    # Expect the attachment to be stored as "attachment-[HASH]-[FILESIZE].txt"
    assert re.match(r"attachment-[0-9a-f]+-[0-9]+.txt", dst_path)
    for attachment_entry in attachment_entries:
        assert attachments[dst_path] == attachment_entry["source_path"]