shill: Acquire IP once the cellular interface is up.
BUG=chromium-os:19175
TEST=unit tests, tested on device
Change-Id: Id319b155047e8e7d6886a28f4d682185104f317f
Reviewed-on: http://gerrit.chromium.org/gerrit/6029
Tested-by: Darin Petkov <petkov@chromium.org>
Reviewed-by: Paul Stewart <pstew@chromium.org>
Reviewed-by: Jason Glasgow <jglasgow@chromium.org>
diff --git a/mock_dhcp_config.h b/mock_dhcp_config.h
new file mode 100644
index 0000000..3572e82
--- /dev/null
+++ b/mock_dhcp_config.h
@@ -0,0 +1,32 @@
+// Copyright (c) 2011 The Chromium OS Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef SHILL_MOCK_DHCP_CONFIG_H_
+#define SHILL_MOCK_DHCP_CONFIG_H_
+
+#include <gmock/gmock.h>
+
+#include "shill/dhcp_config.h"
+
+namespace shill {
+
+class MockDHCPConfig : public DHCPConfig {
+ public:
+ MockDHCPConfig(ControlInterface *control_interface,
+ EventDispatcher *dispatcher,
+ DHCPProvider *provider,
+ const std::string &device_name,
+ GLib *glib)
+ : DHCPConfig(control_interface,
+ dispatcher,
+ provider,
+ device_name,
+ glib) {}
+
+ MOCK_METHOD0(RequestIP, bool());
+};
+
+} // namespace shill
+
+#endif // SHILL_MOCK_DHCP_CONFIG_H_