File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -4,22 +4,24 @@ import Testing
44
55struct UpdateDiagnosticsTests {
66 @Test
7- func `diagnostics include update location and install- origin signals`() throws {
8- let bundleURL = try #require( URL ( string: " file:///Applications/RepoBar.app " ) )
7+ func `diagnostics include update location and install- origin signals`() {
8+ let bundleURL = FileManager . default. temporaryDirectory
9+ . appending ( path: " RepoBarDiagnosticsFixture " , directoryHint: . isDirectory)
10+ . appending ( path: " RepoBar.app " , directoryHint: . isDirectory)
911 let diagnostics = UpdateDiagnostics (
1012 bundleURL: bundleURL,
1113 canCheckForUpdates: true ,
1214 developerIDSigned: true ,
1315 quarantineReader: { _ in true }
1416 )
1517
16- #expect( diagnostics. bundlePath == " /Applications/RepoBar.app " )
18+ #expect( diagnostics. bundlePath == bundleURL . path )
1719 #expect( diagnostics. canCheckForUpdates)
1820 #expect( diagnostics. developerIDSigned)
1921 #expect( ! diagnostics. homebrewCask)
2022 #expect( ! diagnostics. appTranslocated)
2123 #expect( diagnostics. quarantinePresent)
22- #expect( diagnostics. pasteboardText. contains ( " bundle_path: /Applications/RepoBar.app " ) )
24+ #expect( diagnostics. pasteboardText. contains ( " bundle_path: \( bundleURL . path ) " ) )
2325 #expect( diagnostics. pasteboardText. contains ( " quarantine_present: true " ) )
2426 }
2527
You can’t perform that action at this time.
0 commit comments