We define an event handler for OpenURL
And we handle it here:
If I'm debugging in Xcode, I see a SIGCONT before the handler is called. When I continue from the SIGCONT, I enter the handler and everything is fine.
This causes automated tests to break, and is generally a pain in the you-know-where. Outside of Xcode it's fine.
How can I make it stop doing this? Is there some Xcode setting I've overlooked?
Code Block NSAppleEventManager *appleEventManager = [NSAppleEventManager sharedAppleEventManager]; [appleEventManager setEventHandler:self andSelector:@selector(handleGetURLEvent:withReplyEvent:) forEventClass:kInternetEventClass andEventID:kAEGetURL];
And we handle it here:
Code Block - (void)handleGetURLEvent:(NSAppleEventDescriptor *)event withReplyEvent:(NSAppleEventDescriptor *)replyEvent { // Handler type stuff }
If I'm debugging in Xcode, I see a SIGCONT before the handler is called. When I continue from the SIGCONT, I enter the handler and everything is fine.
This causes automated tests to break, and is generally a pain in the you-know-where. Outside of Xcode it's fine.
How can I make it stop doing this? Is there some Xcode setting I've overlooked?
The main problem is UI testing with XCTest, although it also happens with plain debugging.
I've set a symbolic breakpoint on NSApplicationMain, and am runniing process handle -s false SIGCONT with an automatic continue.
It works the first time, but if I stop and re-run the application it will occasionally still break with a SIGCONT, which is a little odd. Much, much, less frequent though.
I've set a symbolic breakpoint on NSApplicationMain, and am runniing process handle -s false SIGCONT with an automatic continue.
It works the first time, but if I stop and re-run the application it will occasionally still break with a SIGCONT, which is a little odd. Much, much, less frequent though.