fix compiler error in testcases

This commit is contained in:
John Estropia
2019-10-25 16:17:25 +09:00
parent 4baeb6d922
commit f3beca8769
6 changed files with 23 additions and 13 deletions

View File

@@ -203,8 +203,8 @@ class ListPublisherTests: BaseTestDataTestCase {
XCTAssertEqual(listPublisher.snapshot.numberOfSections, 2)
XCTAssertTrue(listPublisher.snapshot.hasItems())
XCTAssertTrue(listPublisher.snapshot.hasItems(inSectionIndex: 0))
XCTAssertEqual(listPublisher.snapshot.numberOfItems(inSectionIndex: 0), 2)
XCTAssertEqual(listPublisher.snapshot.numberOfItems(inSectionIndex: 1), 3)
XCTAssertEqual(listPublisher.snapshot.numberOfItems(inSectionIndex: 0), 1)
XCTAssertEqual(listPublisher.snapshot.numberOfItems(inSectionIndex: 1), 4)
didChangeExpectation.fulfill()
}

View File

@@ -56,8 +56,8 @@ class ObjectPublisherTests: BaseTestDataTestCase {
let didChangeExpectation = self.expectation(description: "didChange")
objectPublisher.addObserver(observer) { objectPublisher in
XCTAssertEqual(objectPublisher.snapshot?.testNumber, NSNumber(value: 10))
XCTAssertEqual(objectPublisher.snapshot?.testString, "nil:TestEntity1:10")
XCTAssertEqual(objectPublisher.object?.testNumber, NSNumber(value: 10))
XCTAssertEqual(objectPublisher.object?.testString, "nil:TestEntity1:10")
didChangeExpectation.fulfill()
}