How can i reset the verify count? ```verify(exact...
# mockk
s
How can i reset the verify count?
Copy code
verify(exactly = 1) { mView.showLocations(any()) }

// Reset verify

locationListPresenter.onFilterTextChanged(text)
verify(exactly = 1) { mView.showLocations(any()) }
i am with this isolationMode
IsolationMode.InstancePerLeaf
o
Sorry missed notification. clearMockk should reset I believe. You can customize it to clear all recorded calls, but keep behavior
s
Copy code
Given("filter") {
            val locationListPresenter = LocationListPresenter(mView, mLocationManager, true)
            When("text changed") {
                val text = "test"
                verify(exactly = 1) { mView.showLocations(any()) }
                verify(exactly = 1) { mView.setSelectedItem(any()) }
                locationListPresenter.onFilterTextChanged(text)

                Then("store user first time") {
                    verify(exactly = 2) { mView.showLocations(any()) }
                    verify(exactly = 2) { mView.setSelectedItem(any()) }
                }
            }
        }
No problem @oleksiyp. This is my solution... like LocationListPresenter call the same methods i had to verify two times the methods calls.