testing crash

This commit is contained in:
2018-11-30 14:27:11 +01:00
parent d0919862da
commit 829e8c0b62
12 changed files with 40 additions and 4 deletions

View File

@@ -16,6 +16,6 @@
openURL:(NSURL *)url
options:(NSDictionary<UIApplicationOpenURLOptionsKey, id> *)options;
- (float)sonarpen_pressure;
- (void)hockeyapp_crash;
@end

View File

@@ -27,6 +27,11 @@
return true;
}
- (void)hockeyapp_crash
{
[[[BITHockeyManager sharedHockeyManager] crashManager] generateTestCrash];
}
- (float)sonarpen_pressure
{
return [sonarpen_driver isPenAttached] ? [sonarpen_driver pressure] : 1.f;
@@ -56,7 +61,7 @@
[[BITHockeyManager sharedHockeyManager] configureWithIdentifier:@"c2dccca196294ecca8fd5d58af2738cf"];
// Do some additional configuration if needed here
[[BITHockeyManager sharedHockeyManager] startManager];
[[BITHockeyManager sharedHockeyManager].authenticator authenticateInstallation];
//[[BITHockeyManager sharedHockeyManager].authenticator authenticateInstallation];
// sonarpen_driver = [[WTSonarPenDriver alloc] initWithApplication:application];
// [sonarpen_driver start];
// [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(penStatusChanged) name:WTSonarPenDriverStateChangedNotification object:nil];

View File

@@ -27,4 +27,5 @@
- (void)pick_photo:(std::function<void(std::string)>) callback;
- (void)registerForKeyboardNotifications;
- (void)unregisterForKeyboardNotifications;
- (void)crash;
@end

View File

@@ -42,6 +42,11 @@ NSThread* lock_thread;
std::recursive_mutex lock_mutex;
@implementation GameViewController
- (void)crash
{
AppDelegate* app = (AppDelegate*)[[UIApplication sharedApplication] delegate];
[app hockeyapp_crash];
}
- (void)async_lock
{
lock_mutex.lock();