summaryrefslogtreecommitdiffstats
path: root/tests/DumpRenderTree2/src/com/android/dumprendertree2
diff options
context:
space:
mode:
authorSteve Block <steveblock@google.com>2010-09-21 18:30:01 +0100
committerSteve Block <steveblock@google.com>2010-09-28 19:01:12 +0100
commit27c5fab5715fed6d97ccfdf2d631a3b3726570d3 (patch)
tree92214c78e66448b7849fd2a9b38698e7a72c2898 /tests/DumpRenderTree2/src/com/android/dumprendertree2
parentcdde57ae5c5bc12317f1eababf43bf3a6c2d511e (diff)
downloadframeworks_base-27c5fab5715fed6d97ccfdf2d631a3b3726570d3.zip
frameworks_base-27c5fab5715fed6d97ccfdf2d631a3b3726570d3.tar.gz
frameworks_base-27c5fab5715fed6d97ccfdf2d631a3b3726570d3.tar.bz2
Reduce the AppCache maximum size to a more reasonable value in DumpRenderTree2
Without this change, any use of AppCache fails after the test http/tests/appcache/max-size.html has been run. The test in question passes, but seems to leave the database in a corrupted state, causing all future database transactions to fail. The only fix is to remove the database file. This behaviour is only observed with DumpRenderTree2, not DumpRenderTree, so I don't think this is a WebView problem. I'm not sure what the root cause is, but I think it make sense to submit this fix now in order to get the LayoutTests stable with DumpRenderTree2. Change-Id: I763c09406e66839676b839e3cdeba3b9427c1cb9
Diffstat (limited to 'tests/DumpRenderTree2/src/com/android/dumprendertree2')
-rw-r--r--tests/DumpRenderTree2/src/com/android/dumprendertree2/LayoutTestsExecutor.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/DumpRenderTree2/src/com/android/dumprendertree2/LayoutTestsExecutor.java b/tests/DumpRenderTree2/src/com/android/dumprendertree2/LayoutTestsExecutor.java
index 089af0d..97d7cca 100644
--- a/tests/DumpRenderTree2/src/com/android/dumprendertree2/LayoutTestsExecutor.java
+++ b/tests/DumpRenderTree2/src/com/android/dumprendertree2/LayoutTestsExecutor.java
@@ -382,7 +382,9 @@ public class LayoutTestsExecutor extends Activity {
WebSettings webViewSettings = webView.getSettings();
webViewSettings.setAppCacheEnabled(true);
webViewSettings.setAppCachePath(getApplicationContext().getCacheDir().getPath());
- webViewSettings.setAppCacheMaxSize(Long.MAX_VALUE);
+ // Use of larger values causes unexplained AppCache database corruption.
+ // TODO: Investigate what's really going on here.
+ webViewSettings.setAppCacheMaxSize(100 * 1024 * 1024);
webViewSettings.setJavaScriptEnabled(true);
webViewSettings.setJavaScriptCanOpenWindowsAutomatically(true);
webViewSettings.setSupportMultipleWindows(true);