mirror of
https://github.com/yattee/yattee.git
synced 2025-08-05 02:04:07 +00:00
Improve validation
This commit is contained in:
17
Tests macOS/InstancesModelTests.swift
Normal file
17
Tests macOS/InstancesModelTests.swift
Normal file
@@ -0,0 +1,17 @@
|
||||
import XCTest
|
||||
|
||||
final class InstancesModelTests: XCTestCase {
|
||||
func testStandardizedURL() throws {
|
||||
let samples: [String: String] = [
|
||||
"https://www.youtube.com/": "https://www.youtube.com",
|
||||
"https://www.youtube.com": "https://www.youtube.com",
|
||||
]
|
||||
|
||||
samples.forEach { url, standardized in
|
||||
XCTAssertEqual(
|
||||
InstancesModel.standardizedURL(url),
|
||||
standardized
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user