Complete the code to create a mock of the Calculator class using MockK.
val calculator = [1]<Calculator>()Use mockk to create a mock object in MockK.
Complete the code to stub the add method to return 10 when called with any two integers.
every { calculator.add([1], [1]) } returns 10Use any() to match any argument in MockK stubbing.
Fix the error in verifying that the subtract method was called exactly once with arguments 5 and 3.
verify(exactly = [1]) { calculator.subtract(5, 3) }
Use exactly = 1 to verify the method was called once.
Fill both blanks to create a spy of the Service class and stub its fetchData method to return "data".
val service = [1]<Service>() every { service.[2]() } returns "data"
Use spyk to create a spy and stub the fetchData method.
Fill all three blanks to verify that the save method was called at least twice with any string argument.
verify(atLeast = [1]) { repository.[2]([3]) }
Use atLeast = 2 to check minimum calls, method name save, and any() to match any argument.