Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(267)

Unified Diff: chromecast/base/cast_sys_info_dummy.h

Issue 1466003003: [Chromecast] Add setters to CastSysInfoDummy. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add ForTesting. Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chromecast/base/cast_sys_info_dummy.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromecast/base/cast_sys_info_dummy.h
diff --git a/chromecast/base/cast_sys_info_dummy.h b/chromecast/base/cast_sys_info_dummy.h
index ec6c0eab535aa826e33754eb3f109b36b601cfd4..10d03a82a90abf9278b288b8bf2617a9883a9743 100644
--- a/chromecast/base/cast_sys_info_dummy.h
+++ b/chromecast/base/cast_sys_info_dummy.h
@@ -12,6 +12,7 @@
namespace chromecast {
+// Dummy implementation of CastSysInfo. Fields can be overwritten for test.
class CastSysInfoDummy : public CastSysInfo {
public:
CastSysInfoDummy();
@@ -35,7 +36,42 @@ class CastSysInfoDummy : public CastSysInfo {
std::string GetGlRenderer() override;
std::string GetGlVersion() override;
+ void SetBuildTypeForTesting(BuildType build_type);
+ void SetSystemReleaseChannelForTesting(
+ const std::string& system_release_channel);
+ void SetSerialNumberForTesting(const std::string& serial_number);
+ void SetProductNameForTesting(const std::string& product_name);
+ void SetDeviceModelForTesting(const std::string& device_model);
+ void SetBoardNameForTesting(const std::string& board_name);
+ void SetBoardRevisionForTesting(const std::string& board_revision);
+ void SetManufacturerForTesting(const std::string& manufacturer);
+ void SetSystemBuildNumberForTesting(const std::string& system_build_number);
+ void SetFactoryCountryForTesting(const std::string& factory_country);
+ void SetFactoryLocaleForTesting(const std::string& factory_locale);
+ void SetWifiInterfaceForTesting(const std::string& wifi_interface);
+ void SetApInterfaceForTesting(const std::string& ap_interface);
+ void SetGlVendorForTesting(const std::string& gl_vendor);
+ void SetGlRendererForTesting(const std::string& gl_renderer);
+ void SetGlVersionForTesting(const std::string& gl_version);
+
private:
+ BuildType build_type_;
+ std::string system_release_channel_;
+ std::string serial_number_;
+ std::string product_name_;
+ std::string device_model_;
+ std::string board_name_;
+ std::string board_revision_;
+ std::string manufacturer_;
+ std::string system_build_number_;
+ std::string factory_country_;
+ std::string factory_locale_;
+ std::string wifi_interface_;
+ std::string ap_interface_;
+ std::string gl_vendor_;
+ std::string gl_renderer_;
+ std::string gl_version_;
+
DISALLOW_COPY_AND_ASSIGN(CastSysInfoDummy);
};
« no previous file with comments | « no previous file | chromecast/base/cast_sys_info_dummy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698