@@ -17,6 +17,26 @@ class AuthTests: XCTestCase {
1717 override func setUp( ) {
1818 super. setUp ( )
1919 }
20+
21+ func testAuthFailureReasonDebugDescriptions( ) {
22+ let expectedDescriptions : [ ( AuthFailureReason , String ) ] = [
23+ ( . authTokenExpired, " authTokenExpired " ) ,
24+ ( . authTokenGenericError, " authTokenGenericError " ) ,
25+ ( . authTokenExpirationInvalid, " authTokenExpirationInvalid " ) ,
26+ ( . authTokenSignatureInvalid, " authTokenSignatureInvalid " ) ,
27+ ( . authTokenFormatInvalid, " authTokenFormatInvalid " ) ,
28+ ( . authTokenInvalidated, " authTokenInvalidated " ) ,
29+ ( . authTokenPayloadInvalid, " authTokenPayloadInvalid " ) ,
30+ ( . authTokenUserKeyInvalid, " authTokenUserKeyInvalid " ) ,
31+ ( . authTokenNull, " authTokenNull " ) ,
32+ ( . authTokenGenerationError, " authTokenGenerationError " ) ,
33+ ( . authTokenMissing, " authTokenMissing " )
34+ ]
35+
36+ expectedDescriptions. forEach { reason, description in
37+ XCTAssertEqual ( String ( describing: reason) , description)
38+ }
39+ }
2040
2141 func testEmailPersistence( ) {
2242 let internalAPI = InternalIterableAPI . initializeForTesting ( )
0 commit comments