-
-
Notifications
You must be signed in to change notification settings - Fork 331
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
isEmpty() returns false on empty list #458
Comments
Hey @audunel, can you reproduce this issue while using MockK (1.9.3) only? I cannot see an error here, It looks like this issue belongs to springmockk.
|
Hi @fabiobauer When running your example code, I was not able to reproduce the issue. It seems like there's some other issue with our code. Thank you for your time. |
For others looking for answer: I was having similar issue using mockk_version = '1.10.3-jdk8' Instead of using this:
Use this:
|
This has also been fixed in more recent versions of mockk. |
Prerequisites
Please answer the following questions for yourself before submitting an issue.
Expected Behavior
I am mocking a service which returns a list, and is supposed to return an empty list
Where
foo()
is defined asCurrent Behavior
The test fails as
returnedList.isEmpty()
returns falseFailure Information (for bugs)
I have examined the
returnedList
val, and it has size = 0.Steps to Reproduce
Context
The text was updated successfully, but these errors were encountered: