[TAR] Remove argument label from TarWriter.append

This commit is contained in:
Timofey Solomko
2021-11-21 12:36:56 +03:00
parent eaa0ae4b9b
commit 643f2c9866
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -21,7 +21,7 @@ public struct TarWriter {
self.localPaxHeaderCounter = 0
}
public mutating func append(entry: TarEntry) throws {
public mutating func append(_ entry: TarEntry) throws {
var out = Data()
if format == .gnu {
if entry.info.name.utf8.count > 100 {
+1 -1
View File
@@ -66,7 +66,7 @@ class TarCreateTests: XCTestCase {
try "".write(to: tempFileUrl, atomically: true, encoding: .utf8)
let handle = try FileHandle(forWritingTo: tempFileUrl)
var writer = TarWriter(fileHandle: handle)
try writer.append(entry: entry)
try writer.append(entry)
try writer.finalize()
let containerData = try Data(contentsOf: tempFileUrl)
XCTAssertEqual(try TarContainer.formatOf(container: containerData), .pax)