Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 11 additions & 2 deletions Tests/AuspexCoreTests/DeliverySnapshotTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -148,12 +148,21 @@ struct DeliverySnapshotTests {
#expect(Set(dirty.changedFiles.map(\.path)) == ["tracked.txt", "new.txt"])
}

/// Fixture setup, not a product path: a loaded GitHub runner can spend
/// seconds just starting `/usr/bin/git`, and a timeout here fails with an
/// empty stderr that says nothing about the assertions below. The 1.5-second
/// bound the product actually relies on lives in `GitDeliveryReader`.
private func git(_ arguments: [String], in directory: URL) throws {
let result = ProcessGitCommandRunner().run(
in: directory, arguments: arguments, timeout: 3, maxOutputBytes: 16 * 1_024
in: directory, arguments: arguments, timeout: 30, maxOutputBytes: 16 * 1_024
)
guard result.exitCode == 0 else {
throw GitTestError.failed(result.stderr)
throw GitTestError.failed(
result.stderr.isEmpty
? "git \(arguments.joined(separator: " ")) produced no stderr; "
+ "exit \(result.exitCode), most likely the fixture timeout"
: result.stderr
)
}
}
}
Expand Down
Loading