IOS-1542 Move most important methods together. IOS-1542
authorDirk Zimmermann <dz@pep.security>
Wed, 08 May 2019 15:52:44 +0200
branchIOS-1542
changeset 8533906cca3f17bc
parent 8532 f125044bbfae
child 8534 7b84e81b5c39
IOS-1542 Move most important methods together.
pEpForiOSTests/TestUtils/TestDataBase.swift
     1.1 --- a/pEpForiOSTests/TestUtils/TestDataBase.swift	Wed May 08 15:52:44 2019 +0200
     1.2 +++ b/pEpForiOSTests/TestUtils/TestDataBase.swift	Wed May 08 15:52:44 2019 +0200
     1.3 @@ -220,28 +220,6 @@
     1.4          addLocalTestAccount(userName: "test003")
     1.5      }
     1.6  
     1.7 -    private func addLocalTestAccount(userName: String) {
     1.8 -        let address = "\(userName)@localhost"
     1.9 -        append(accountSettings: AccountSettings(
    1.10 -            accountName: "Unit Test \(address)",
    1.11 -            idAddress: address,
    1.12 -            idUserName: "User \(address)",
    1.13 -
    1.14 -            imapLoginName: userName,
    1.15 -            imapServerAddress: "localhost",
    1.16 -            imapServerType: Server.ServerType.imap,
    1.17 -            imapServerTransport: Server.Transport.plain,
    1.18 -            imapServerPort: 3143,
    1.19 -
    1.20 -            smtpLoginName: userName,
    1.21 -            smtpServerAddress: "localhost",
    1.22 -            smtpServerType: Server.ServerType.smtp,
    1.23 -            smtpServerTransport: Server.Transport.plain,
    1.24 -            smtpServerPort: 3025,
    1.25 -
    1.26 -            password: "pwd"))
    1.27 -    }
    1.28 -
    1.29      /**
    1.30       Accounts needed for testing LAS, that is they need to be registered
    1.31       in the LAS DB or provide (correct) DNS SRV for IMAP and SMTP.
    1.32 @@ -268,6 +246,28 @@
    1.33          fatalError("Abstract method. Must be overridden")
    1.34      }
    1.35  
    1.36 +    private func addLocalTestAccount(userName: String) {
    1.37 +        let address = "\(userName)@localhost"
    1.38 +        append(accountSettings: AccountSettings(
    1.39 +            accountName: "Unit Test \(address)",
    1.40 +            idAddress: address,
    1.41 +            idUserName: "User \(address)",
    1.42 +
    1.43 +            imapLoginName: userName,
    1.44 +            imapServerAddress: "localhost",
    1.45 +            imapServerType: Server.ServerType.imap,
    1.46 +            imapServerTransport: Server.Transport.plain,
    1.47 +            imapServerPort: 3143,
    1.48 +
    1.49 +            smtpLoginName: userName,
    1.50 +            smtpServerAddress: "localhost",
    1.51 +            smtpServerType: Server.ServerType.smtp,
    1.52 +            smtpServerTransport: Server.Transport.plain,
    1.53 +            smtpServerPort: 3025,
    1.54 +
    1.55 +            password: "pwd"))
    1.56 +    }
    1.57 +
    1.58      /**
    1.59       - Returns: A valid `CdAccount`.
    1.60       */