Skip to content

Instantly share code, notes, and snippets.

@TsuyoshiUshio
Created April 30, 2020 18:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save TsuyoshiUshio/d117b9c6e6c16bee4f7c4d2c4a601d8b to your computer and use it in GitHub Desktop.
Save TsuyoshiUshio/d117b9c6e6c16bee4f7c4d2c4a601d8b to your computer and use it in GitHub Desktop.
import org.junit.*;
import mockit.*;
import static org.junit.Assert.assertEquals;
public class InvocationRequestTest {
@Mocked
private ParameterBinding binding;
@Test
public void test(@Tested final Some some) throws Exception {
new Expectations() {{
binding.getName(); result = "ushio";
}};
assertEquals("ushio", binding.getName());
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment