Test açıklaması

public final class TestDescription
extends Object

java.lang.Object
com.android.tradefed.result.TestDescription


Bir test senaryosu hakkındaki bilgileri temsil eden sınıf.

Özet

Alanlar

public static final Pattern PARAMETERIZED_TEST_REGEX

Parametrelendirilmiş yöntem için normal ifade.

Kamu inşaatçıları

TestDescription (String className, String testName)

Oluşturucu

TestDescription (String className, String testName, Annotation... annotations)

Oluşturucu

TestDescription (String className, String testName, annotations) TestDescription (String className, String testName, annotations)

Oluşturucu

Genel yöntemler

int compareTo ( TestDescription o)
static TestIdentifier convertToIdentifier ( TestDescription desc)

TestDescription bir TestIdentifier oluşturun.

static TestDescription createFromTestIdentifier (TestIdentifier testId)

TestIdentifier bir TestDescription oluşturun.

boolean equals (Object obj)
static TestDescription fromString (String data)

toString() } temsilinden bir TestDescription oluşturun.

<T extends Annotation> T getAnnotation (Class<T> annotationType)
getAnnotations ()
String getClassName ()

Testin tam nitelikli sınıf adını döndürür.

String getTestName ()

Parametreli test ise, parametrelerle birlikte testin adını döndürür.

String getTestNameWithoutParams ()

Testin adını herhangi bir parametre olmadan döndürür (eğer parametreli bir yöntemse).

int hashCode ()
String toString ()

Alanlar

PARAMETERIZED_TEST_REGEX

public static final Pattern PARAMETERIZED_TEST_REGEX

Parametrelendirilmiş yöntem için normal ifade. Örneğin: testAdı[0]

Kamu inşaatçıları

Test açıklaması

public TestDescription (String className, 
                String testName)

Oluşturucu

Parametreler
className String : Testin yapıldığı sınıfın adı.

testName String : Test (yöntem) adı.

Test açıklaması

public TestDescription (String className, 
                String testName, 
                Annotation... annotations)

Oluşturucu

Parametreler
className String : Testin yapıldığı sınıfın adı.

testName String : Test (yöntem) adı.

annotations Annotation : Test senaryosuyla ilişkili ERROR(/Annotation) listesi.

Test açıklaması

public TestDescription (String className, 
                String testName, 
                 annotations)

Oluşturucu

Parametreler
className String : Testin yapıldığı sınıfın adı.

testName String : Test (yöntem) adı.

annotations : Test senaryosuyla ilişkili ERROR(/Annotation) koleksiyonu.

Genel yöntemler

karşılaştırmak

public int compareTo (TestDescription o)

Parametreler
o TestDescription

İadeler
int

ConvertToIdentifier

public static TestIdentifier convertToIdentifier (TestDescription desc)

TestDescription bir TestIdentifier oluşturun. Test sırasında bir açıklamayı dönüştürmek için kullanışlıdır.

Parametreler
desc TestDescription : Dönüştürülecek TestDescription .

İadeler
TestIdentifier TestDescription değerleriyle oluşturulan TestIdentifier .

createFromTestIdentifier

public static TestDescription createFromTestIdentifier (TestIdentifier testId)

TestIdentifier bir TestDescription oluşturun. Birinden diğerine dönüştürme kolaylığı için kullanılır.

Parametreler
testId TestIdentifier : Dönüştürülecek TestIdentifier .

İadeler
TestDescription TestIdentifier değerleriyle oluşturulan TestDescription .

eşittir

public boolean equals (Object obj)

Parametreler
obj Object

İadeler
boolean

fromString

public static TestDescription fromString (String data)

toString() } temsilinden bir TestDescription oluşturun.

Parametreler
data String : String gösterimi. Beklenen format: sınıf adı#yöntem adı

İadeler
TestDescription TestDescription veya ayrıştırılamadıysa null

getAnnotation

public T getAnnotation (Class<T> annotationType)

Parametreler
annotationType Class

İadeler
T bu açıklama düğümüne eklenen annotationType türündeki ek açıklama veya mevcut değilse null

getEk açıklamalar

public  getAnnotations ()

İadeler
bu açıklama düğümüne eklenen tüm ek açıklamalar

getClassName

public String getClassName ()

Testin tam nitelikli sınıf adını döndürür.

İadeler
String

getTestName

public String getTestName ()

Parametreli test ise, parametrelerle birlikte testin adını döndürür. Parametreli bir test değilse normal test adını döndürür.

İadeler
String

getTestNameWithoutParams

public String getTestNameWithoutParams ()

Testin adını herhangi bir parametre olmadan döndürür (eğer parametreli bir yöntemse).

İadeler
String

hash kodu

public int hashCode ()

İadeler
int

toString

public String toString ()

İadeler
String