Add logic for more customizable password generator
This commit is contained in:
parent
49a371d495
commit
ff014a5699
10 changed files with 352 additions and 131 deletions
21
passKitTests/Passwords/PasswordGeneratorFlavorTest.swift
Normal file
21
passKitTests/Passwords/PasswordGeneratorFlavorTest.swift
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
//
|
||||
// PasswordGeneratorFlavorTest.swift
|
||||
// passKitTests
|
||||
//
|
||||
// Created by Danny Moesch on 28.11.18.
|
||||
// Copyright © 2018 Bob Sun. All rights reserved.
|
||||
//
|
||||
|
||||
import XCTest
|
||||
|
||||
@testable import passKit
|
||||
|
||||
class PasswordGeneratorFlavorTest: XCTestCase {
|
||||
|
||||
func testLengthLimits() {
|
||||
// Ensure properly chosen length limits. So this check no longer needs to be performed in the code.
|
||||
PasswordGeneratorFlavor.allCases.map { $0.lengthLimits }.forEach {
|
||||
XCTAssertLessThanOrEqual($0.min, $0.max)
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue