Use folder references for all groups and sort files/folders
This commit is contained in:
parent
38b44cedf8
commit
d698f2e3c3
12 changed files with 154 additions and 154 deletions
|
|
@ -1,45 +0,0 @@
|
|||
//
|
||||
// StringExtensionTest.swift
|
||||
// passKitTests
|
||||
//
|
||||
// Created by Danny Moesch on 30.09.18.
|
||||
// Copyright © 2018 Bob Sun. All rights reserved.
|
||||
//
|
||||
|
||||
import XCTest
|
||||
|
||||
@testable import passKit
|
||||
|
||||
class StringExtensionTest: XCTestCase {
|
||||
|
||||
func testTrimmed() {
|
||||
[
|
||||
(" ", ""),
|
||||
(" \n\t\r", ""),
|
||||
("\t a \n b \t c \r d \n ", "a \n b \t c \r d"),
|
||||
].forEach { untrimmed, trimmed in
|
||||
XCTAssertEqual(untrimmed.trimmed, trimmed)
|
||||
}
|
||||
}
|
||||
|
||||
func testStringByAddingPercentEncodingForRFC3986() {
|
||||
[
|
||||
("!#$&'()*+,/:;=?@[]^", "%21%23%24%26%27%28%29%2A%2B%2C/%3A%3B%3D?%40%5B%5D%5E"),
|
||||
("-._~/?", "-._~/?"),
|
||||
("A*b!c", "A%2Ab%21c"),
|
||||
].forEach { unencoded, encoded in
|
||||
XCTAssertEqual(unencoded.stringByAddingPercentEncodingForRFC3986(), encoded)
|
||||
}
|
||||
}
|
||||
|
||||
func testConcatenateAsLines() {
|
||||
[
|
||||
("a" | "b", "a\nb"),
|
||||
("" | "b", "\nb"),
|
||||
("a" | "", "a"),
|
||||
("" | "", ""),
|
||||
].forEach { concatenated, result in
|
||||
XCTAssertEqual(concatenated, result)
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue