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

Unified Diff: components/filesystem/directory_impl_unittest.cc

Issue 1157573002: Revert "Update mojo sdk to rev 1dc8a9a5db73d3718d99917fadf31f5fb2ebad4f" (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « build/module_args/mojo.gni ('k') | components/filesystem/file_impl_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/filesystem/directory_impl_unittest.cc
diff --git a/components/filesystem/directory_impl_unittest.cc b/components/filesystem/directory_impl_unittest.cc
index 556d3237f9378fff541c58b3f64bc9c5345d7d37..c702295c417d25199506899402ddfd2f9393e9fe 100644
--- a/components/filesystem/directory_impl_unittest.cc
+++ b/components/filesystem/directory_impl_unittest.cc
@@ -30,7 +30,7 @@ TEST_F(DirectoryImplTest, Read) {
error = ERROR_INTERNAL;
directory->OpenFile(files_to_create[i].name, nullptr,
files_to_create[i].open_flags, Capture(&error));
- ASSERT_TRUE(directory.WaitForIncomingResponse());
+ ASSERT_TRUE(directory.WaitForIncomingMethodCall());
EXPECT_EQ(ERROR_OK, error);
}
// Make a directory.
@@ -38,13 +38,13 @@ TEST_F(DirectoryImplTest, Read) {
directory->OpenDirectory("my_dir", nullptr,
kOpenFlagRead | kOpenFlagWrite | kOpenFlagCreate,
Capture(&error));
- ASSERT_TRUE(directory.WaitForIncomingResponse());
+ ASSERT_TRUE(directory.WaitForIncomingMethodCall());
EXPECT_EQ(ERROR_OK, error);
error = ERROR_INTERNAL;
mojo::Array<DirectoryEntryPtr> directory_contents;
directory->Read(Capture(&error, &directory_contents));
- ASSERT_TRUE(directory.WaitForIncomingResponse());
+ ASSERT_TRUE(directory.WaitForIncomingMethodCall());
EXPECT_EQ(ERROR_OK, error);
// Expected contents of the directory.
@@ -81,7 +81,7 @@ TEST_F(DirectoryImplTest, StatTouch) {
error = ERROR_INTERNAL;
FileInformationPtr file_info;
directory->Stat(Capture(&error, &file_info));
- ASSERT_TRUE(directory.WaitForIncomingResponse());
+ ASSERT_TRUE(directory.WaitForIncomingMethodCall());
EXPECT_EQ(ERROR_OK, error);
ASSERT_FALSE(file_info.is_null());
EXPECT_EQ(FILE_TYPE_DIRECTORY, file_info->type);
@@ -100,14 +100,14 @@ TEST_F(DirectoryImplTest, StatTouch) {
const int64_t kPartyTime1 = 1234567890; // Party like it's 2009-02-13.
t->timespec->seconds = kPartyTime1;
directory->Touch(t.Pass(), nullptr, Capture(&error));
- ASSERT_TRUE(directory.WaitForIncomingResponse());
+ ASSERT_TRUE(directory.WaitForIncomingMethodCall());
EXPECT_EQ(ERROR_OK, error);
// Stat again.
error = ERROR_INTERNAL;
file_info.reset();
directory->Stat(Capture(&error, &file_info));
- ASSERT_TRUE(directory.WaitForIncomingResponse());
+ ASSERT_TRUE(directory.WaitForIncomingMethodCall());
EXPECT_EQ(ERROR_OK, error);
ASSERT_FALSE(file_info.is_null());
ASSERT_FALSE(file_info->atime.is_null());
@@ -122,14 +122,14 @@ TEST_F(DirectoryImplTest, StatTouch) {
const int64_t kPartyTime2 = 1425059525; // No time like the present.
t->timespec->seconds = kPartyTime2;
directory->Touch(nullptr, t.Pass(), Capture(&error));
- ASSERT_TRUE(directory.WaitForIncomingResponse());
+ ASSERT_TRUE(directory.WaitForIncomingMethodCall());
EXPECT_EQ(ERROR_OK, error);
// Stat again.
error = ERROR_INTERNAL;
file_info.reset();
directory->Stat(Capture(&error, &file_info));
- ASSERT_TRUE(directory.WaitForIncomingResponse());
+ ASSERT_TRUE(directory.WaitForIncomingMethodCall());
EXPECT_EQ(ERROR_OK, error);
ASSERT_FALSE(file_info.is_null());
ASSERT_FALSE(file_info->atime.is_null());
@@ -152,41 +152,41 @@ TEST_F(DirectoryImplTest, BasicRenameDelete) {
error = ERROR_INTERNAL;
directory->OpenFile("my_file", nullptr, kOpenFlagWrite | kOpenFlagCreate,
Capture(&error));
- ASSERT_TRUE(directory.WaitForIncomingResponse());
+ ASSERT_TRUE(directory.WaitForIncomingMethodCall());
EXPECT_EQ(ERROR_OK, error);
// Opening my_file should succeed.
error = ERROR_INTERNAL;
directory->OpenFile("my_file", nullptr, kOpenFlagRead, Capture(&error));
- ASSERT_TRUE(directory.WaitForIncomingResponse());
+ ASSERT_TRUE(directory.WaitForIncomingMethodCall());
EXPECT_EQ(ERROR_OK, error);
// Rename my_file to my_new_file.
directory->Rename("my_file", "my_new_file", Capture(&error));
- ASSERT_TRUE(directory.WaitForIncomingResponse());
+ ASSERT_TRUE(directory.WaitForIncomingMethodCall());
EXPECT_EQ(ERROR_OK, error);
// Opening my_file should fail.
error = ERROR_INTERNAL;
directory->OpenFile("my_file", nullptr, kOpenFlagRead, Capture(&error));
- ASSERT_TRUE(directory.WaitForIncomingResponse());
+ ASSERT_TRUE(directory.WaitForIncomingMethodCall());
EXPECT_EQ(ERROR_UNKNOWN, error);
// Opening my_new_file should succeed.
error = ERROR_INTERNAL;
directory->OpenFile("my_new_file", nullptr, kOpenFlagRead, Capture(&error));
- ASSERT_TRUE(directory.WaitForIncomingResponse());
+ ASSERT_TRUE(directory.WaitForIncomingMethodCall());
EXPECT_EQ(ERROR_OK, error);
// Delete my_new_file (no flags).
directory->Delete("my_new_file", 0, Capture(&error));
- ASSERT_TRUE(directory.WaitForIncomingResponse());
+ ASSERT_TRUE(directory.WaitForIncomingMethodCall());
EXPECT_EQ(ERROR_OK, error);
// Opening my_new_file should fail.
error = ERROR_INTERNAL;
directory->OpenFile("my_new_file", nullptr, kOpenFlagRead, Capture(&error));
- ASSERT_TRUE(directory.WaitForIncomingResponse());
+ ASSERT_TRUE(directory.WaitForIncomingMethodCall());
EXPECT_EQ(ERROR_UNKNOWN, error);
}
« no previous file with comments | « build/module_args/mojo.gni ('k') | components/filesystem/file_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698