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

Side by Side Diff: ipc/mojo/async_handle_waiter_unittest.cc

Issue 1554443003: Stop linking in the old Mojo EDK. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: merge and fix new flaky test Created 4 years, 11 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 | « ipc/mojo/async_handle_waiter.cc ('k') | ipc/mojo/client_channel.mojom » ('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 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 "ipc/mojo/async_handle_waiter.h" 5 #include "ipc/mojo/async_handle_waiter.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 void WaitAndAssertSignaledAndMessageIsArrived() { 70 void WaitAndAssertSignaledAndMessageIsArrived() {
71 run_loop_->Run(); 71 run_loop_->Run();
72 EXPECT_EQ(MOJO_RESULT_OK, signaled_result_); 72 EXPECT_EQ(MOJO_RESULT_OK, signaled_result_);
73 73
74 ReadOneByteOfX(pipe_to_read_.get().value()); 74 ReadOneByteOfX(pipe_to_read_.get().value());
75 } 75 }
76 76
77 void WaitAndAssertNotSignaled() { 77 void WaitAndAssertNotSignaled() {
78 run_loop_->RunUntilIdle(); 78 run_loop_->RunUntilIdle();
79 EXPECT_EQ(MOJO_RESULT_OK, MojoWait(pipe_to_read_.get().value(), 79 EXPECT_EQ(MOJO_RESULT_OK, MojoWait(pipe_to_read_.get().value(),
80 MOJO_HANDLE_SIGNAL_READABLE, 0, 80 MOJO_HANDLE_SIGNAL_READABLE,
81 nullptr)); 81 MOJO_DEADLINE_INDEFINITE, nullptr));
82 EXPECT_EQ(MOJO_RESULT_UNKNOWN, signaled_result_); 82 EXPECT_EQ(MOJO_RESULT_UNKNOWN, signaled_result_);
83 } 83 }
84 84
85 void HandleIsReady(MojoResult result) { 85 void HandleIsReady(MojoResult result) {
86 CHECK_EQ(base::MessageLoop::current(), message_loop_.get()); 86 CHECK_EQ(base::MessageLoop::current(), message_loop_.get());
87 CHECK_EQ(signaled_result_, MOJO_RESULT_UNKNOWN); 87 CHECK_EQ(signaled_result_, MOJO_RESULT_UNKNOWN);
88 signaled_result_ = result; 88 signaled_result_ = result;
89 run_loop_->Quit(); 89 run_loop_->Quit();
90 } 90 }
91 91
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
251 target_->GetIOObserverForTest()->DidProcessIOEvent(); 251 target_->GetIOObserverForTest()->DidProcessIOEvent();
252 EXPECT_EQ(0U, invocation_count_); 252 EXPECT_EQ(0U, invocation_count_);
253 253
254 target_->GetIOObserverForTest()->DidProcessIOEvent(); 254 target_->GetIOObserverForTest()->DidProcessIOEvent();
255 EXPECT_EQ(1U, invocation_count_); 255 EXPECT_EQ(1U, invocation_count_);
256 } 256 }
257 257
258 } // namespace 258 } // namespace
259 } // namespace internal 259 } // namespace internal
260 } // namespace IPC 260 } // namespace IPC
OLDNEW
« no previous file with comments | « ipc/mojo/async_handle_waiter.cc ('k') | ipc/mojo/client_channel.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698