Skip to content
This repository was archived by the owner on Feb 2, 2021. It is now read-only.

Fix check for ios simulator #811

Merged
merged 1 commit into from
Sep 28, 2016

Conversation

TsvetanMilanov
Copy link
Contributor

When we check if there is running simulator we use ps cax but if the simulator is killed for a short period of time after that there is a process listed when using ps cax and we decide that there is a running simulator and then we try to use it but ios-sim-portable returns null. We should check if the simulator returned from ios-sim-portable is not null or undefined in order to continue to work with it.

@TsvetanMilanov TsvetanMilanov self-assigned this Sep 26, 2016
@justcodebuilduser
Copy link

💔

@TsvetanMilanov TsvetanMilanov force-pushed the milanov/fix-check-for-ios-simulator branch from 8d04d28 to 5c810da Compare September 26, 2016 14:14
@justcodebuilduser
Copy link

❤️


function createTestInjector(): IInjector {
let injector = new Yok();
injector.register("childProcess", {
exec: (command: string) => Future.fromResult(isCurrentlyRunning ? 'launchd_sim' : '')
exec: (command: string) => Future.fromResult("")
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe you no longer need this mock of childProcess

When we check if there is running simulator we use ps cax but if the simulator is killed for a short period of time after that there is a process listed when using ps cax and we decide that there is a running simulator and then we try to use it but ios-sim-portable returns null. We should check if the simulator returned from ios-sim-portable is not null or undefined in order to continue to work with it.
@TsvetanMilanov TsvetanMilanov force-pushed the milanov/fix-check-for-ios-simulator branch from 5c810da to 78b3b81 Compare September 28, 2016 14:05
@justcodebuilduser
Copy link

❤️

@TsvetanMilanov TsvetanMilanov merged commit d9ae37a into master Sep 28, 2016
@TsvetanMilanov TsvetanMilanov deleted the milanov/fix-check-for-ios-simulator branch September 28, 2016 14:25
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants