SpongeUtils
public
final
class
SpongeUtils
extends Object
| java.lang.Object | |
| ↳ | com.google.android.tradefed.result.teststorage.SpongeUtils |
這個類別用於保存處理 Sponge 的輔助方法。
摘要
公用建構函式 | |
|---|---|
SpongeUtils()
|
|
公用方法 | |
|---|---|
static
String
|
createInvocationId()
建立 Sponge 叫用 ID。 |
static
String
|
createSpongeV1Url(String url, String runName)
為測試執行建立 Sponge V1 網址。 |
static
String
|
createSpongeV2Url(String invocationId, String runName)
為測試執行建立 Sponge V2 網址。 |
static
String
|
getInvocationUrl(String invocationId)
Gets the https url to the invocation displayed on sponge v2 UI. |
公用建構函式
SpongeUtils
public SpongeUtils ()
公用方法
createInvocationId
public static String createInvocationId ()
建立 Sponge 叫用 ID。
| 傳回 | |
|---|---|
String |
隨機 Sponge 叫用 ID。 |
createSpongeV1Url
public static String createSpongeV1Url (String url,
String runName)為測試執行建立 Sponge V1 網址。它會將 target=runName 網址參數新增至基本 Sponge 網址。
| 參數 | |
|---|---|
url |
String:- 基礎 Sponge 網址。 |
runName |
String:測試執行作業的名稱 |
| 傳回 | |
|---|---|
String |
海綿網址,且額外目標參數已設為 runName。 |
createSpongeV2Url
public static String createSpongeV2Url (String invocationId,
String runName)為測試執行建立 Sponge V2 網址。這會將目標設為 runName。
| 參數 | |
|---|---|
invocationId |
String:- Sponge 叫用 ID。 |
runName |
String:測試執行作業的名稱 |
| 傳回 | |
|---|---|
String |
海綿網址,額外目標設為 runName。 |
getInvocationUrl
public static String getInvocationUrl (String invocationId)
取得顯示在 Sponge V2 UI 上的叫用 HTTPS 網址。
| 參數 | |
|---|---|
invocationId |
String |
| 傳回 | |
|---|---|
String |
https 網址或 null (如無法提供前者) |