public async Task Test_GetSensorCountPerMonth_Successful() { _mockauditDataProvider.Setup(a => a.GetStateCountPerMonth(It.IsAny <string>(), It.IsAny <string>(), It.IsAny <string>())).Returns( new Outcome <int> { Result = 20 } ); var result = await sensorsController.GetSensorCountPerMonth(It.IsAny <string>(), It.IsAny <string>()); Assert.IsNotNull(result); Assert.IsInstanceOfType(result, typeof(Microsoft.AspNetCore.Mvc.ActionResult <int>)); }