async def test_parameterized_memory_block(memory_with_blocks):
    """Test memory block that accepts parameters."""
    # Get memory block content with parameter
    content = await memory_with_blocks._get_memory_blocks_content(
        [], test_parameter="custom_value"
    )

    # Verify parameter was passed through
    assert "param_block" in content
    assert content["param_block"] == "Parameter value: custom_value"

    # Try with default parameter
    content = await memory_with_blocks._get_memory_blocks_content([])
    assert content["param_block"] == "Parameter value: default"
Test memory block that accepts parameters.
llama-index-core/tests/memory/test_memory_blocks_base.py