aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaramie Leavitt <lar@google.com>2024-07-10 11:28:46 -0700
committerCopybara-Service <copybara-worker@google.com>2024-07-10 11:29:42 -0700
commitbb50cad0adb77f6afdab1d50c093aae2b36d0522 (patch)
tree4530be475dc3c9a9c07a91441f2b91e5589a2e70
parent6dee153242d7becebe026a9bed52f4114441719d (diff)
downloadabseil-bb50cad0adb77f6afdab1d50c093aae2b36d0522.tar.gz
abseil-bb50cad0adb77f6afdab1d50c093aae2b36d0522.tar.bz2
abseil-bb50cad0adb77f6afdab1d50c093aae2b36d0522.zip
Use GetStatus in IsOkAndHoldsMatcher
PiperOrigin-RevId: 651093644 Change-Id: Ia5bb3343ef06529d5fa2d469bcad47451ea79c69
-rw-r--r--absl/status/internal/status_matchers.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/absl/status/internal/status_matchers.h b/absl/status/internal/status_matchers.h
index d11742b7..0750622e 100644
--- a/absl/status/internal/status_matchers.h
+++ b/absl/status/internal/status_matchers.h
@@ -69,8 +69,8 @@ class IsOkAndHoldsMatcherImpl
bool MatchAndExplain(
StatusOrType actual_value,
::testing::MatchResultListener* result_listener) const override {
- if (!actual_value.ok()) {
- *result_listener << "which has status " << actual_value.status();
+ if (!GetStatus(actual_value).ok()) {
+ *result_listener << "which has status " << GetStatus(actual_value);
return false;
}