♻️ Append terminator

This commit is contained in:
Chris Araman 2021-04-28 21:10:50 -07:00
parent fec436070d
commit d0738e50b6
No known key found for this signature in database
GPG key ID: BB4499D9E11B61E0
2 changed files with 5 additions and 1 deletions

View file

@ -19,7 +19,10 @@ var printObserver: ((String) -> Void)?
// See MasKitTests/OutputListener.swift.
func print(_ items: Any..., separator: String = " ", terminator: String = "\n") {
if let observer = printObserver {
let output = items.map { "\($0)" }.joined(separator: separator)
let output = items
.map { "\($0)" }
.joined(separator: separator)
.appending(terminator)
observer(output)
}

View file

@ -33,6 +33,7 @@ class InfoCommandSpec: QuickSpec {
Minimum OS: 10.14
Size: 1 KB
From: https://awesome.app
"""
describe("Info command") {