 extension AuthManagerSpec {
 
     func testIsAuthenticatedUserNotAuthenticated() {
-        XCTAssert(AuthManager.isAuthenticated() == nil, "isAuthenticated returns nil for non authenticated users")
+        XCTAssert(authManager.isAuthenticated() == nil, "isAuthenticated returns nil for non authenticated users")
     }
 
     func testIsAuthenticatedUserAuthenticated() {


@testable import Rocket_Chat

class AuthManagerSpec: XCTestCase {

    override func setUp() {
        super.setUp()

        // Clear all the Auth objects in Realm
        Realm.executeOnMainThread({ realm in


            realm.add(auth)

            XCTAssert(self.authManager.isAuthenticated()?.serverURL == auth.serverURL, "isAuthenticated returns Auth instance")
        })
    }

