diff --git a/test/core/xds/xds_client_test_lib.h b/test/core/xds/xds_client_test_lib.h index 3a7bad4a71c84..74dd475ae6484 100644 --- a/test/core/xds/xds_client_test_lib.h +++ b/test/core/xds/xds_client_test_lib.h @@ -247,6 +247,10 @@ class XdsClientTestBase : public ::testing::Test { int resource_value() const { return resource_->value; } + std::shared_ptr resource() const { + return resource_; + } + private: std::shared_ptr resource_; RefCountedPtr read_delay_handle_; @@ -297,7 +301,7 @@ class XdsClientTestBase : public ::testing::Test { if (!resource_and_handle.has_value()) { return nullptr; } - return std::move(resource_and_handle->first); + return resource_and_handle->resource(); } absl::optional WaitForNextError(