diff --git a/base/json/json_parser.h b/base/json/json_parser.h index b4d0b1bf977a81..4e23beb9289595 100644 --- a/base/json/json_parser.h +++ b/base/json/json_parser.h @@ -10,31 +10,14 @@ #include "base/base_export.h" #include "base/basictypes.h" #include "base/compiler_specific.h" +#include "base/gtest_prod_util.h" #include "base/json/json_reader.h" #include "base/strings/string_piece.h" -#if !defined(OS_CHROMEOS) -#include "base/gtest_prod_util.h" -#endif - namespace base { -class Value; -} -#if defined(OS_CHROMEOS) -// Chromium and Chromium OS check out gtest to different places, so this is -// unable to compile on both if gtest_prod.h is included here. Instead, include -// its only contents -- this will need to be updated if the macro ever changes. -#define FRIEND_TEST(test_case_name, test_name)\ -friend class test_case_name##_##test_name##_Test - -#define FRIEND_TEST_ALL_PREFIXES(test_case_name, test_name) \ - FRIEND_TEST(test_case_name, test_name); \ - FRIEND_TEST(test_case_name, DISABLED_##test_name); \ - FRIEND_TEST(test_case_name, FLAKY_##test_name) -#endif // OS_CHROMEOS +class Value; -namespace base { namespace internal { class JSONParserTest; diff --git a/jingle/notifier/base/xmpp_connection.h b/jingle/notifier/base/xmpp_connection.h index bc1ec2a1e48cd5..946a6deb9fe596 100644 --- a/jingle/notifier/base/xmpp_connection.h +++ b/jingle/notifier/base/xmpp_connection.h @@ -22,7 +22,7 @@ class PreXmppAuth; class XmlElement; class XmppClientSettings; class XmppTaskParentInterface; -} // namespace +} // namespace buzz namespace jingle_glue { class TaskPump; @@ -80,6 +80,13 @@ class XmppConnection ~XmppConnection() override; private: + FRIEND_TEST_ALL_PREFIXES(XmppConnectionTest, RaisedError); + FRIEND_TEST_ALL_PREFIXES(XmppConnectionTest, Connect); + FRIEND_TEST_ALL_PREFIXES(XmppConnectionTest, MultipleConnect); + FRIEND_TEST_ALL_PREFIXES(XmppConnectionTest, ConnectThenError); + FRIEND_TEST_ALL_PREFIXES(XmppConnectionTest, + TasksDontRunAfterXmppConnectionDestructor); + void OnStateChange(buzz::XmppEngine::State state); void OnInputLog(const char* data, int len); void OnOutputLog(const char* data, int len); @@ -91,12 +98,6 @@ class XmppConnection bool on_connect_called_; Delegate* delegate_; - FRIEND_TEST(XmppConnectionTest, RaisedError); - FRIEND_TEST(XmppConnectionTest, Connect); - FRIEND_TEST(XmppConnectionTest, MultipleConnect); - FRIEND_TEST(XmppConnectionTest, ConnectThenError); - FRIEND_TEST(XmppConnectionTest, TasksDontRunAfterXmppConnectionDestructor); - DISALLOW_COPY_AND_ASSIGN(XmppConnection); };