From 52d04d998caeb508e2a829e2d233eba692d5d03b Mon Sep 17 00:00:00 2001 From: Michael Housh Date: Wed, 15 Mar 2023 14:49:50 -0400 Subject: [PATCH] Version 0.1.0 --- Tests/CliVersionTests/CliVersionTests.swift | 23 ++++++++++----------- 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/Tests/CliVersionTests/CliVersionTests.swift b/Tests/CliVersionTests/CliVersionTests.swift index 1c9c234..a93d0f5 100644 --- a/Tests/CliVersionTests/CliVersionTests.swift +++ b/Tests/CliVersionTests/CliVersionTests.swift @@ -47,22 +47,21 @@ final class GitVersionTests: XCTestCase { } func test_commands() throws { - @Dependency(\.shellClient) var shellClient + @Dependency(\.shellClient) var shellClient: ShellClient - let branch = try shellClient.background( - .gitCurrentBranch(gitDirectory: gitDir), - trimmingCharactersIn: .whitespacesAndNewlines + XCTAssertNoThrow( + try shellClient.background( + .gitCurrentBranch(gitDirectory: gitDir), + trimmingCharactersIn: .whitespacesAndNewlines + ) ) - print("BRANCH: \(branch)") - XCTAssertEqual(branch, "main") - let commit = try shellClient.background( - .gitCurrentSha(gitDirectory: gitDir), - trimmingCharactersIn: .whitespacesAndNewlines + XCTAssertNoThrow( + try shellClient.background( + .gitCurrentSha(gitDirectory: gitDir), + trimmingCharactersIn: .whitespacesAndNewlines + ) ) - print("COMMIT: \(commit)") - XCTAssertNotEqual(commit, "") - } func test_file_client() throws {