Internal Code Change
PiperOrigin-RevId: 519071084 Change-Id: I6459d60606e93bf658e505544538367508722857
This commit is contained in:
		
				
					committed by
					
						
						Copybara-Service
					
				
			
			
				
	
			
			
			
						parent
						
							6f01e3dc12
						
					
				
				
					commit
					a0ced33ac6
				
			@@ -181,7 +181,7 @@ class GTEST_API_ AssertionResult {
 | 
			
		||||
  // assertion's expectation). When nothing has been streamed into the
 | 
			
		||||
  // object, returns an empty string.
 | 
			
		||||
  const char* message() const {
 | 
			
		||||
    return message_.get() != nullptr ? message_->c_str() : "";
 | 
			
		||||
    return message_ != nullptr ? message_->c_str() : "";
 | 
			
		||||
  }
 | 
			
		||||
  // Deprecated; please use message() instead.
 | 
			
		||||
  const char* failure_message() const { return message(); }
 | 
			
		||||
@@ -204,7 +204,7 @@ class GTEST_API_ AssertionResult {
 | 
			
		||||
 private:
 | 
			
		||||
  // Appends the contents of message to message_.
 | 
			
		||||
  void AppendMessage(const Message& a_message) {
 | 
			
		||||
    if (message_.get() == nullptr) message_.reset(new ::std::string);
 | 
			
		||||
    if (message_ == nullptr) message_.reset(new ::std::string);
 | 
			
		||||
    message_->append(a_message.GetString().c_str());
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -551,14 +551,14 @@ class GTEST_API_ TestInfo {
 | 
			
		||||
  // Returns the name of the parameter type, or NULL if this is not a typed
 | 
			
		||||
  // or a type-parameterized test.
 | 
			
		||||
  const char* type_param() const {
 | 
			
		||||
    if (type_param_.get() != nullptr) return type_param_->c_str();
 | 
			
		||||
    if (type_param_ != nullptr) return type_param_->c_str();
 | 
			
		||||
    return nullptr;
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  // Returns the text representation of the value parameter, or NULL if this
 | 
			
		||||
  // is not a value-parameterized test.
 | 
			
		||||
  const char* value_param() const {
 | 
			
		||||
    if (value_param_.get() != nullptr) return value_param_->c_str();
 | 
			
		||||
    if (value_param_ != nullptr) return value_param_->c_str();
 | 
			
		||||
    return nullptr;
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
@@ -697,7 +697,7 @@ class GTEST_API_ TestSuite {
 | 
			
		||||
  // Returns the name of the parameter type, or NULL if this is not a
 | 
			
		||||
  // type-parameterized test suite.
 | 
			
		||||
  const char* type_param() const {
 | 
			
		||||
    if (type_param_.get() != nullptr) return type_param_->c_str();
 | 
			
		||||
    if (type_param_ != nullptr) return type_param_->c_str();
 | 
			
		||||
    return nullptr;
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user