I have installed the trial version of JustMock to evaluate it. I have been trying to mock the static calls of Azure RoleEnvironment class, but the SetupStatic does not work. It seems to be calling the original method. Please see my simple test below: [Test] public void VerifyRoleEnvironment() { bool expected = true; Mock.SetupStatic(typeof(RoleEnvironment), StaticConstructor.Mocked); Mock.Arrange(() => RoleEnvironment.IsAvailable).Returns(true); Assert.AreEqual(expected, RoleEnvironment.IsAvailable); }