OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include <string> | 5 #include <string> |
6 | 6 |
7 #include "base/macros.h" | 7 #include "base/macros.h" |
8 #include "base/strings/string16.h" | 8 #include "base/strings/string16.h" |
9 #include "base/strings/utf_string_conversions.h" | 9 #include "base/strings/utf_string_conversions.h" |
10 #include "chrome/browser/usb/web_usb_detector.h" | 10 #include "chrome/browser/usb/web_usb_detector.h" |
11 #include "device/core/mock_device_client.h" | 11 #include "device/base/mock_device_client.h" |
12 #include "device/usb/mock_usb_device.h" | 12 #include "device/usb/mock_usb_device.h" |
13 #include "device/usb/mock_usb_service.h" | 13 #include "device/usb/mock_usb_service.h" |
14 #include "testing/gtest/include/gtest/gtest.h" | 14 #include "testing/gtest/include/gtest/gtest.h" |
15 #include "ui/message_center/message_center.h" | 15 #include "ui/message_center/message_center.h" |
16 #include "ui/message_center/notification.h" | 16 #include "ui/message_center/notification.h" |
17 #include "ui/message_center/notification_delegate.h" | 17 #include "ui/message_center/notification_delegate.h" |
18 #include "url/gurl.h" | 18 #include "url/gurl.h" |
19 | 19 |
20 namespace { | 20 namespace { |
21 | 21 |
(...skipping 370 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
392 base::ASCIIToUTF16("Go to www.google.com/C to connect."); | 392 base::ASCIIToUTF16("Go to www.google.com/C to connect."); |
393 EXPECT_EQ(expected_message_3, notification_3->message()); | 393 EXPECT_EQ(expected_message_3, notification_3->message()); |
394 EXPECT_TRUE(notification_3->delegate() != nullptr); | 394 EXPECT_TRUE(notification_3->delegate() != nullptr); |
395 | 395 |
396 device_client_.usb_service()->RemoveDevice(device_1); | 396 device_client_.usb_service()->RemoveDevice(device_1); |
397 EXPECT_EQ(nullptr, message_center_->FindVisibleNotificationById(guid_1)); | 397 EXPECT_EQ(nullptr, message_center_->FindVisibleNotificationById(guid_1)); |
398 | 398 |
399 device_client_.usb_service()->RemoveDevice(device_3); | 399 device_client_.usb_service()->RemoveDevice(device_3); |
400 EXPECT_EQ(nullptr, message_center_->FindVisibleNotificationById(guid_3)); | 400 EXPECT_EQ(nullptr, message_center_->FindVisibleNotificationById(guid_3)); |
401 } | 401 } |
OLD | NEW |