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

Side by Side Diff: media/midi/usb_midi_input_stream_unittest.cc

Issue 1086073004: Web MIDI: namespace change from media to media::midi (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@null
Patch Set: (rebase) Created 5 years, 7 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 unified diff | Download patch
« no previous file with comments | « media/midi/usb_midi_input_stream.cc ('k') | media/midi/usb_midi_jack.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "media/midi/usb_midi_input_stream.h" 5 #include "media/midi/usb_midi_input_stream.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
11 #include "base/strings/stringprintf.h" 11 #include "base/strings/stringprintf.h"
12 #include "base/time/time.h" 12 #include "base/time/time.h"
13 #include "media/midi/usb_midi_device.h" 13 #include "media/midi/usb_midi_device.h"
14 #include "testing/gtest/include/gtest/gtest.h" 14 #include "testing/gtest/include/gtest/gtest.h"
15 15
16 using base::TimeTicks; 16 using base::TimeTicks;
17 17
18 namespace media { 18 namespace media {
19 namespace midi {
19 20
20 namespace { 21 namespace {
21 22
22 class TestUsbMidiDevice : public UsbMidiDevice { 23 class TestUsbMidiDevice : public UsbMidiDevice {
23 public: 24 public:
24 TestUsbMidiDevice() {} 25 TestUsbMidiDevice() {}
25 ~TestUsbMidiDevice() override {} 26 ~TestUsbMidiDevice() override {}
26 std::vector<uint8> GetDescriptors() override { return std::vector<uint8>(); } 27 std::vector<uint8> GetDescriptors() override { return std::vector<uint8>(); }
27 std::string GetManufacturer() override { return std::string(); } 28 std::string GetManufacturer() override { return std::string(); }
28 std::string GetProductName() override { return std::string(); } 29 std::string GetProductName() override { return std::string(); }
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 167
167 TEST_F(UsbMidiInputStreamTest, DispatchForDevice2) { 168 TEST_F(UsbMidiInputStreamTest, DispatchForDevice2) {
168 uint8 data[] = { 0x4f, 0xf8, 0x00, 0x00 }; 169 uint8 data[] = { 0x4f, 0xf8, 0x00, 0x00 };
169 170
170 stream_->OnReceivedData(&device2_, 7, data, arraysize(data), TimeTicks()); 171 stream_->OnReceivedData(&device2_, 7, data, arraysize(data), TimeTicks());
171 EXPECT_EQ("0xf8 \n", delegate_.received_data()); 172 EXPECT_EQ("0xf8 \n", delegate_.received_data());
172 } 173 }
173 174
174 } // namespace 175 } // namespace
175 176
177 } // namespace midi
176 } // namespace media 178 } // namespace media
OLDNEW
« no previous file with comments | « media/midi/usb_midi_input_stream.cc ('k') | media/midi/usb_midi_jack.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698