def test_middleware_response_headers(raw_context_app):
    """
    Test that middleware adds the expected headers to the response.
    """
    with TestClient(raw_context_app) as client:
        response = client.get("/")
        assert response.status_code == HTTP_200_OK

        # Check that the expected headers are set in the response
        assert plugins.RequestIdPlugin.key.lower() in response.headers
        assert plugins.CorrelationIdPlugin.key.lower() in response.headers

    Test that middleware adds the expected headers to the response.
    
tests/test_starlette_compatibility.py