Index: net/test/remote_test_server.cc |
diff --git a/net/test/remote_test_server.cc b/net/test/remote_test_server.cc |
index 5020ca7f0c0dfe45f6e4037d3fa55358cf9ecbc9..71cf9360b4fbcc4c244ddcb20349a91c862304b2 100644 |
--- a/net/test/remote_test_server.cc |
+++ b/net/test/remote_test_server.cc |
@@ -183,5 +183,14 @@ bool RemoteTestServer::Init(const FilePath& document_root) { |
return true; |
} |
+// On Android, the document root in device is not the same as the document root |
+// in host machine where test server is launched. So append DIR_SOURCE_ROOT |
wtc
2012/10/23 18:28:31
1. This method should be defined between Stop() an
Shouqun Liu
2012/10/24 02:32:47
Done.
|
+// here to get the actual path of document root on Android device. |
+FilePath RemoteTestServer::GetDocumentRoot() const { |
+ FilePath src_dir; |
+ PathService::Get(base::DIR_SOURCE_ROOT, &src_dir); |
+ return src_dir.Append(document_root()); |
+} |
+ |
} // namespace net |