<commit_before>//
//  SwiftyTextTableTests.swift
//  SwiftyTextTableTests
//
//  Created by <NAME> on 2/3/16.
//  Copyright © 2016 <NAME>. All rights reserved.
//

import XCTest
import SwiftyTextTable

class SwiftyTextTableTests: XCTestCase {

    var table: TextTable!

    override func setUp() {
        super.setUp()
        let foo = TextTableColumn(header: "foo")
        let bar = TextTableColumn(header: "bar")
        let baz = TextTableColumn(header: "baz")
        table = TextTable(columns: [foo, bar, baz])
        table.addRow("1", "2")
        table.addRow(11, 22, 33)
        table.addRow(111, 222, 333, 444)
    }

    func testRenderDefault() {
        let output = table.render()
        let expected = "+-----+-----+-----+\n" +
                       "| foo | bar | baz |\n" +
                       "+-----+-----+-----+\n" +
                       "| 1   | 2   |     |\n" +
                       "| 11  | 22  | 33  |\n" +
                       "| 111 | 222 | 333 |\n" +
                       "+-----+-----+-----+"
        XCTAssertEqual(output, expected)
    }

    func testRenderCustom() {
        table.columnFence = "!"
        table.rowFence = "*"
        table.cornerFence = "."
        let output = table.render()
        let expected = ".*****.*****.*****.\n" +
                       "! foo ! bar ! baz !\n" +
                       ".*****.*****.*****.\n" +
                       "! 1   ! 2   !     !\n" +
                       "! 11  ! 22  ! 33  !\n" +
                       "! 111 ! 222 ! 333 !\n" +
                       ".*****.*****.*****."
        XCTAssertEqual(output, expected)
    }

    // MARK: - protocol XCTestCaseProvider for SPM
    lazy var allTests: [(String, () throws -> Void)] = [
        ("testRenderDefault", self.testRenderDefault),
        ("testRenderCustom", self.testRenderCustom)
    ]
}
<commit_msg>Fix test failure for SPM<commit_after>//
//  SwiftyTextTableTests.swift
//  SwiftyTextTableTests
//
//  Created by <NAME> on 2/3/16.
//  Copyright © 2016 <NAME>. All rights reserved.
//

import XCTest
import SwiftyTextTable

class SwiftyTextTableTests: XCTestCase {

    func fooTable() -> TextTable {
        let foo = TextTableColumn(header: "foo")
        let bar = TextTableColumn(header: "bar")
        let baz = TextTableColumn(header: "baz")
        var table = TextTable(columns: [foo, bar, baz])
        table.addRow("1", "2")
        table.addRow(11, 22, 33)
        table.addRow(111, 222, 333, 444)
        return table
    }

    func testRenderDefault() {
        let output = fooTable().render()
        let expected = "+-----+-----+-----+\n" +
                       "| foo | bar | baz |\n" +
                       "+-----+-----+-----+\n" +
                       "| 1   | 2   |     |\n" +
                       "| 11  | 22  | 33  |\n" +
                       "| 111 | 222 | 333 |\n" +
                       "+-----+-----+-----+"
        XCTAssertEqual(output, expected)
    }

    func testRenderCustom() {
        var table = fooTable()
        table.columnFence = "!"
        table.rowFence = "*"
        table.cornerFence = "."
        let output = table.render()
        let expected = ".*****.*****.*****.\n" +
                       "! foo ! bar ! baz !\n" +
                       ".*****.*****.*****.\n" +
                       "! 1   ! 2   !     !\n" +
                       "! 11  ! 22  ! 33  !\n" +
                       "! 111 ! 222 ! 333 !\n" +
                       ".*****.*****.*****."
        XCTAssertEqual(output, expected)
    }

    // MARK: - protocol XCTestCaseProvider for SPM
    lazy var allTests: [(String, () throws -> Void)] = [
        ("testRenderDefault", self.testRenderDefault),
        ("testRenderCustom", self.testRenderCustom)
    ]
}

{'fraction_non_alphanumeric': 0.1875664187035069, 'fraction_numerical': 0.03294367693942614, 'mean_word_length': 1.3240740740740742, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 10, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6739183', 'n_tokens_mistral': 1296, 'n_tokens_neox': 1122, 'n_words': 256}