useEmulator

abstract fun useEmulator(host: String = "10.0.2.2", port: Int = 9399)(source)

Connects to the Data Connect emulator instead of the production service; must be called before any operation is executed. The default host is the one the Android emulator reaches its host machine with; the other platforms' tests use localhost.