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

Unified Diff: chrome/browser/android/offline_pages/offline_page_utils_unittest.cc

Issue 1551033002: Convert Pass()→std::move() in //chrome (Android edition) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Enable RVO by making types match Created 5 years 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: chrome/browser/android/offline_pages/offline_page_utils_unittest.cc
diff --git a/chrome/browser/android/offline_pages/offline_page_utils_unittest.cc b/chrome/browser/android/offline_pages/offline_page_utils_unittest.cc
index 8f343027eb62757a6d4b06e5ea561ff741724428..6a0c8f18732f98f2784be0576d4d26aab1b0e2e5 100644
--- a/chrome/browser/android/offline_pages/offline_page_utils_unittest.cc
+++ b/chrome/browser/android/offline_pages/offline_page_utils_unittest.cc
@@ -5,6 +5,7 @@
#include "chrome/browser/android/offline_pages/offline_page_utils.h"
#include <stdint.h>
+#include <utility>
#include "base/callback.h"
#include "base/command_line.h"
@@ -121,21 +122,18 @@ void OfflinePageUtilsTest::CreateOfflinePages() {
OfflinePageModelFactory::GetForBrowserContext(profile());
// Create page 1.
- scoped_ptr<OfflinePageTestArchiver> archiver(
- BuildArchiver(kTestPage1Url,
- base::FilePath(FILE_PATH_LITERAL("page1.mhtml")))
- .Pass());
+ scoped_ptr<OfflinePageTestArchiver> archiver(BuildArchiver(
+ kTestPage1Url, base::FilePath(FILE_PATH_LITERAL("page1.mhtml"))));
model->SavePage(
- kTestPage1Url, kTestPage1BookmarkId, archiver.Pass(),
+ kTestPage1Url, kTestPage1BookmarkId, std::move(archiver),
base::Bind(&OfflinePageUtilsTest::OnSavePageDone, AsWeakPtr()));
RunUntilIdle();
// Create page 2.
archiver = BuildArchiver(kTestPage2Url,
- base::FilePath(FILE_PATH_LITERAL("page2.mhtml")))
- .Pass();
+ base::FilePath(FILE_PATH_LITERAL("page2.mhtml")));
model->SavePage(
- kTestPage2Url, kTestPage2BookmarkId, archiver.Pass(),
+ kTestPage2Url, kTestPage2BookmarkId, std::move(archiver),
base::Bind(&OfflinePageUtilsTest::OnSavePageDone, AsWeakPtr()));
RunUntilIdle();
@@ -159,7 +157,7 @@ scoped_ptr<OfflinePageTestArchiver> OfflinePageUtilsTest::BuildArchiver(
this, url, OfflinePageArchiver::ArchiverResult::SUCCESSFULLY_CREATED,
kTestFileSize, base::ThreadTaskRunnerHandle::Get()));
archiver->set_filename(file_name);
- return archiver.Pass();
+ return archiver;
}
// Simple test for offline page model having any pages loaded.

Powered by Google App Engine
This is Rietveld 408576698