Added support for running tests under an emulator.