Skip to content

Commit

Permalink
Fix Riot tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
pixlwave committed Jul 14, 2022
1 parent c781667 commit a529389
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,6 @@ import XCTest

// Then the view data should correctly represent the homeserver.
XCTAssertEqual(viewData.address, "matrix.org", "The displayed address should match the address supplied by the user, but without the scheme.")
XCTAssertEqual(viewData.isMatrixDotOrg, true, "The server should be detected as matrix.org.")
XCTAssertTrue(viewData.showLoginForm, "The login form should be shown.")
XCTAssertEqual(viewData.ssoIdentityProviders, ssoIdentityProviders, "The sso identity providers should match.")
XCTAssertTrue(viewData.showRegistrationForm, "The registration form should be shown.")
Expand All @@ -270,7 +269,6 @@ import XCTest

// Then the view data should correctly represent the homeserver.
XCTAssertEqual(viewData.address, "example.com", "The displayed address should match the address supplied by the user, but without the scheme.")
XCTAssertEqual(viewData.isMatrixDotOrg, false, "The server should not be detected as matrix.org.")
XCTAssertTrue(viewData.showLoginForm, "The login form should be shown.")
XCTAssertEqual(viewData.ssoIdentityProviders, [], "There shouldn't be any sso identity providers.")
XCTAssertFalse(viewData.showRegistrationForm, "The registration form should not be shown.")
Expand All @@ -291,7 +289,6 @@ import XCTest

// Then the view data should correctly represent the homeserver.
XCTAssertEqual(viewData.address, "company.com", "The displayed address should match the address supplied by the user, but without the scheme.")
XCTAssertEqual(viewData.isMatrixDotOrg, false, "The server should not be detected as matrix.org.")
XCTAssertFalse(viewData.showLoginForm, "The login form should not be shown.")
XCTAssertEqual(viewData.ssoIdentityProviders, ssoIdentityProviders, "The sso identity providers should match.")
XCTAssertFalse(viewData.showRegistrationForm, "The registration form should not be shown.")
Expand All @@ -311,7 +308,6 @@ import XCTest

// Then the view data should correctly represent the homeserver.
XCTAssertEqual(viewData.address, "http://localhost:8008", "The displayed address should match address supplied by the user, complete with the scheme.")
XCTAssertEqual(viewData.isMatrixDotOrg, false, "The server should not be detected as matrix.org.")
XCTAssertTrue(viewData.showLoginForm, "The login form should be shown.")
XCTAssertEqual(viewData.ssoIdentityProviders, [], "There shouldn't be any sso identity providers.")
XCTAssertTrue(viewData.showRegistrationForm, "The registration form should be shown.")
Expand Down
12 changes: 0 additions & 12 deletions RiotTests/OnboardingTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -58,18 +58,6 @@ class OnboardingTests: XCTestCase {
XCTAssertEqual(properties.useCase, .skipped)
}

func testCustomServerUseCase() {
// Given an empty set of user properties
let properties = UserSessionProperties(userId: userId)

// When storing a custom server case result
let result = OnboardingUseCaseViewModelResult.customServer
properties.useCase = result.userSessionPropertyValue

// Then the use case property should return nil
XCTAssertNil(properties.useCase)
}

func testUseCaseAfterDeletingProperties() {
// Given a set of user properties with the Work Messaging use case
let properties = UserSessionProperties(userId: userId)
Expand Down

0 comments on commit a529389

Please sign in to comment.