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

Unified Diff: chrome/android/javatests/src/org/chromium/chrome/browser/tabmodel/RestoreMigrateTest.java

Issue 868323003: Begin uniting the TabPersistentStore and StorageDelegate (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: nits Created 5 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 side-by-side diff with in-line comments
Download patch
Index: chrome/android/javatests/src/org/chromium/chrome/browser/tabmodel/RestoreMigrateTest.java
diff --git a/chrome/android/javatests/src/org/chromium/chrome/browser/tabmodel/RestoreMigrateTest.java b/chrome/android/javatests/src/org/chromium/chrome/browser/tabmodel/RestoreMigrateTest.java
index 8434d035bb1c7d68c4286f8efb5953695053e3c9..55480332f4f30dd1dcf59ccdef5ed707394ae01c 100644
--- a/chrome/android/javatests/src/org/chromium/chrome/browser/tabmodel/RestoreMigrateTest.java
+++ b/chrome/android/javatests/src/org/chromium/chrome/browser/tabmodel/RestoreMigrateTest.java
@@ -32,7 +32,8 @@ public class RestoreMigrateTest extends InstrumentationTestCase {
return TabPersistentStore.serializeTabModelSelector(selector);
}
});
- File f = TabPersistentStore.getStateFolder(getInstrumentation().getTargetContext(), index);
+ File f = TabPersistentStore.getStateDirectory(
+ getInstrumentation().getTargetContext(), index);
FileOutputStream fos = null;
try {
fos = new FileOutputStream(new File(f, TabPersistentStore.SAVED_STATE_FILE));
@@ -84,7 +85,8 @@ public class RestoreMigrateTest extends InstrumentationTestCase {
TabPersistentStore.waitForMigrationToFinish();
// Check that the files were moved.
- File newDir = TabPersistentStore.getStateFolder(getInstrumentation().getTargetContext(), 0);
+ File newDir =
+ TabPersistentStore.getStateDirectory(getInstrumentation().getTargetContext(), 0);
File newStateFile = new File(newDir, TabPersistentStore.SAVED_STATE_FILE);
File newTab0 = new File(newDir, TabState.SAVED_TAB_STATE_FILE_PREFIX + "0");
File newTab1 = new File(newDir, TabState.SAVED_TAB_STATE_FILE_PREFIX + "1");
@@ -132,7 +134,8 @@ public class RestoreMigrateTest extends InstrumentationTestCase {
assertTrue("Could not create tab 3 file", tab3.createNewFile());
// Write new state files
- File newDir = TabPersistentStore.getStateFolder(getInstrumentation().getTargetContext(), 0);
+ File newDir =
+ TabPersistentStore.getStateDirectory(getInstrumentation().getTargetContext(), 0);
File newStateFile = new File(newDir, TabPersistentStore.SAVED_STATE_FILE);
File newTab4 = new File(newDir, TabState.SAVED_TAB_STATE_FILE_PREFIX + "4");
@@ -195,7 +198,8 @@ public class RestoreMigrateTest extends InstrumentationTestCase {
assertTrue("Could not find other file", otherFile.exists());
// Check that the files were moved.
- File newDir = TabPersistentStore.getStateFolder(getInstrumentation().getTargetContext(), 0);
+ File newDir =
+ TabPersistentStore.getStateDirectory(getInstrumentation().getTargetContext(), 0);
File newStateFile = new File(newDir, TabPersistentStore.SAVED_STATE_FILE);
File newTab0 = new File(newDir, TabState.SAVED_TAB_STATE_FILE_PREFIX + "0");
File newOtherFile = new File(newDir, "other.file");

Powered by Google App Engine
This is Rietveld 408576698