-
Notifications
You must be signed in to change notification settings - Fork 151
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Reorganize test cases #59
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fantastic work on a simplification to our test suite, thanks 🙇
@@ -91,6 +105,10 @@ class ActionTests: QuickSpec { | |||
next(20, false), | |||
]) | |||
} | |||
|
|||
it("executes twice") { | |||
XCTAssertEqual(executionObservables.events.count, 2) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since the tests use Quick/Nimble, I think using a Nimble matcher instead of XCTAssert
s might make sense. Something like expect(executionObservables) == 2
. What do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, we can use Nimble matchers here. I used XCTAssertEqual in other places for matching Recorded<Event<T>>
, which is provided in RxTests, but other than that, Nimble matchers might be better choice.
I'll replace the matchers that can be replaced by Nimble matchers.
@ashfurrow Thank you for reviewing. I've just replaced the matchers in 1b816f2! |
Most test cases that I added in #56 overlap existing test cases, but they're written in different way. The new tests check logic on the virtual time. IMHO, the new test method is more appropriate for testing Rx library, so I would like to replace the old tests by the new tests.