Prefs: Implement and use Prefs::GetBoolean/SetBoolean.

Adds a pair of functions GetBoolean/SetBoolean to the list Prefs
class to read and write persisted boolean values. The stored
values are not compatible with the SetInt64 and will return
false when attempting to get or set a value of the other type.

These functions are now used to store the update over cellular
user setting.

BUG=chromium:213401
TEST=sudo ./update_engine_unittests

Change-Id: I44107e33f8e81ae900671d9ba6a4f5779c2353db
Reviewed-on: https://gerrit.chromium.org/gerrit/61352
Reviewed-by: Joy Chen <joychen@chromium.org>
Tested-by: Alex Deymo <deymo@chromium.org>
Reviewed-by: mukesh agrawal <quiche@chromium.org>
Commit-Queue: Alex Deymo <deymo@chromium.org>
diff --git a/prefs_mock.h b/prefs_mock.h
index 4f991fc..a5492e2 100644
--- a/prefs_mock.h
+++ b/prefs_mock.h
@@ -19,6 +19,9 @@
   MOCK_METHOD2(GetInt64, bool(const std::string& key, int64_t* value));
   MOCK_METHOD2(SetInt64, bool(const std::string& key, const int64_t value));
 
+  MOCK_METHOD2(GetBoolean, bool(const std::string& key, bool* value));
+  MOCK_METHOD2(SetBoolean, bool(const std::string& key, const bool value));
+
   MOCK_METHOD1(Exists, bool(const std::string& key));
   MOCK_METHOD1(Delete, bool(const std::string& key));
 };