Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 package org.chromium.base.test; | |
| 6 | |
| 7 /** | |
| 8 * Collection of URL utilities. | |
| 9 */ | |
| 10 public class UrlUtils { | |
| 11 private final static String DATA_DIR = "file:///data/local/tmp/chrome/test/d ata/"; | |
| 12 | |
| 13 /** | |
| 14 * Construct a suitable URL for loading a test data file. | |
| 15 * | |
| 16 * @param path Pathname relative to <chrome_src>/chrome/test/data/android/de vice_files/ | |
|
joth
2012/09/05 20:13:06
See https://chromiumcodereview.appspot.com/1091109
| |
| 17 */ | |
| 18 public static String getTestFileUrl(String path) { | |
| 19 return DATA_DIR + path; | |
| 20 } | |
| 21 | |
| 22 /** | |
| 23 * Construct a suitable URL for loading a test data file from the hosts's | |
|
joth
2012/09/05 20:13:06
nit: remove one s, and make less ambiguous: the lo
| |
| 24 * http server. | |
| 25 * | |
| 26 * @param path Pathname relative to the document root. | |
| 27 * @return an http url. | |
| 28 */ | |
| 29 public static String getTestHttpUrl(String path) { | |
| 30 return TestHttpServerClient.getUrl(path); | |
| 31 } | |
| 32 } | |
| OLD | NEW |