Google is committed to advancing racial equity for Black communities. See how.
Added in API level 1
Deprecated in API level 26

TestMethod

open class TestMethod
kotlin.Any
   ↳ android.test.suitebuilder.TestMethod

Represents a test to be run. Can be constructed without instantiating the TestCase or even loading the class.

Summary

Public constructors
<init>(method: Method!, enclosingClass: Class<out TestCase!>!)

<init>(methodName: String!, enclosingClass: Class<out TestCase!>!)

<init>(testCase: TestCase!)

Public methods
open TestCase!

open Boolean
equals(other: Any?)

open T
getAnnotation(annotationClass: Class<T>!)

open Class<out TestCase!>!

open String!

open String!

open Int

open String

Public constructors

<init>

Added in API level 1
TestMethod(
    method: Method!,
    enclosingClass: Class<out TestCase!>!)

<init>

Added in API level 3
TestMethod(
    methodName: String!,
    enclosingClass: Class<out TestCase!>!)

<init>

Added in API level 3
TestMethod(testCase: TestCase!)

Public methods

createTest

Added in API level 1
Deprecated in API level 26
open fun createTest(): TestCase!

Deprecated.

equals

Added in API level 1
Deprecated in API level 26
open fun equals(other: Any?): Boolean

Deprecated.

Parameters
obj the reference object with which to compare.
Return
Boolean true if this object is the same as the obj argument; false otherwise.

getAnnotation

Added in API level 1
Deprecated in API level 26
open fun <T : Annotation!> getAnnotation(annotationClass: Class<T>!): T

Deprecated.

getEnclosingClass

Added in API level 1
Deprecated in API level 26
open fun getEnclosingClass(): Class<out TestCase!>!

Deprecated.

getEnclosingClassname

Added in API level 1
Deprecated in API level 26
open fun getEnclosingClassname(): String!

Deprecated.

getName

Added in API level 1
Deprecated in API level 26
open fun getName(): String!

Deprecated.

hashCode

Added in API level 1
Deprecated in API level 26
open fun hashCode(): Int

Deprecated.

Return
Int a hash code value for this object.

toString

Added in API level 1
Deprecated in API level 26
open fun toString(): String

Deprecated.

Return
String a string representation of the object.