mirror of
https://github.com/sparkle-project/Sparkle
synced 2026-11-26 04:57:54 +00:00
Remove NTSynchronousTask from SUCodeSigningVerifierTest
This commit is contained in:
1 parent
c6df59c7b0
commit
f88eec8105
1 file changed
+11
-8
@@ -8,7 +8,6 @@
|
||||
|
||||
#import <Cocoa/Cocoa.h>
|
||||
#import <XCTest/XCTest.h>
|
||||
#import "NTSynchronousTask.h"
|
||||
#import "SUCodeSigningVerifier.h"
|
||||
|
||||
@interface SUCodeSigningVerifierTest : XCTestCase
|
||||
@@ -115,10 +114,14 @@
|
||||
BOOL success = NO;
|
||||
@try
|
||||
{
|
||||
NTSynchronousTask *task = [[NTSynchronousTask alloc] init];
|
||||
NSArray *arguments = @[ zipPath ];
|
||||
[task run:@"/usr/bin/unzip" directory:destPath withArgs:arguments input:nil];
|
||||
success = ([task result] == 0);
|
||||
NSTask *task = [[NSTask alloc] init];
|
||||
task.launchPath = @"/usr/bin/unzip";
|
||||
task.currentDirectoryPath = destPath;
|
||||
task.arguments = @[zipPath];
|
||||
|
||||
[task launch];
|
||||
[task waitUntilExit];
|
||||
success = (task.terminationStatus == 0);
|
||||
}
|
||||
@catch (NSException *exception)
|
||||
{
|
||||
@@ -134,9 +137,9 @@
|
||||
{
|
||||
// ad-hoc signing with the dash
|
||||
NSArray *arguments = @[ @"--force", @"--deep", @"--sign", @"-", appPath ];
|
||||
NTSynchronousTask *task = [[NTSynchronousTask alloc] init];
|
||||
[task run:@"/usr/bin/codesign" directory:nil withArgs:arguments input:nil];
|
||||
success = ([task result] == 0);
|
||||
NSTask *task = [NSTask launchedTaskWithLaunchPath:@"/usr/bin/codesign" arguments:arguments];
|
||||
[task waitUntilExit];
|
||||
success = (task.terminationStatus == 0);
|
||||
}
|
||||
@catch (NSException *exception)
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user