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

Unified Diff: content/shell/renderer/layout_test/blink_test_runner.cc

Issue 1325953002: Add functions to let tests read and control the Bluetooth chooser state. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkcr
Patch Set: Created 5 years, 4 months 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
Index: content/shell/renderer/layout_test/blink_test_runner.cc
diff --git a/content/shell/renderer/layout_test/blink_test_runner.cc b/content/shell/renderer/layout_test/blink_test_runner.cc
index a3cd68cc43e1fde714659414bddd30a36ea6cf4c..acc09e98fed8814abe75b11b67d6dc8d8bf60a65 100644
--- a/content/shell/renderer/layout_test/blink_test_runner.cc
+++ b/content/shell/renderer/layout_test/blink_test_runner.cc
@@ -475,6 +475,25 @@ void BlinkTestRunner::SetDeviceColorProfile(const std::string& name) {
void BlinkTestRunner::SetBluetoothMockDataSet(const std::string& name) {
Send(new LayoutTestHostMsg_SetBluetoothAdapter(name));
+ // Auto-reset the chooser type so we don't get order dependence when some
+ // tests forget to do it explicitly.
+ Send(new ShellViewHostMsg_SetBluetoothManualChooser(routing_id(), false));
+}
+
+void BlinkTestRunner::SetBluetoothManualChooser() {
+ Send(new ShellViewHostMsg_SetBluetoothManualChooser(routing_id(), true));
+}
+std::vector<std::string> BlinkTestRunner::GetBluetoothManualChooserEvents() {
+ std::vector<std::string> result;
+ Send(new ShellViewHostMsg_GetBluetoothManualChooserEvents(routing_id(),
+ &result));
+ return result;
+}
+void BlinkTestRunner::SendBluetoothManualChooserEvent(
+ const std::string& event,
+ const std::string& argument) {
+ Send(new ShellViewHostMsg_SendBluetoothManualChooserEvent(routing_id(), event,
+ argument));
}
void BlinkTestRunner::SetGeofencingMockProvider(bool service_available) {

Powered by Google App Engine
This is Rietveld 408576698