use of com.hazelcast.simulator.common.TestCase in project hazelcast-simulator by hazelcast.
the class PropertyBindingTest method loadAsLong_nonExisting.
@Test
public void loadAsLong_nonExisting() {
TestCase testCase = new TestCase("foo");
PropertyBinding binding = new PropertyBinding(testCase);
assertEquals(10, binding.loadAsLong("longValue", 10));
}
use of com.hazelcast.simulator.common.TestCase in project hazelcast-simulator by hazelcast.
the class PropertyBindingTest method loadAsInt_existing_withUnderscores.
@Test
public void loadAsInt_existing_withUnderscores() {
TestCase testCase = new TestCase("foo").setProperty("intValue", "5_0");
PropertyBinding binding = new PropertyBinding(testCase);
assertEquals(50, binding.loadAsInt("intValue", 10));
}
use of com.hazelcast.simulator.common.TestCase in project hazelcast-simulator by hazelcast.
the class PropertyBindingTest method loadAsBoolean_nonExisting.
@Test
public void loadAsBoolean_nonExisting() {
TestCase testCase = new TestCase("foo");
PropertyBinding binding = new PropertyBinding(testCase);
assertEquals(true, binding.loadAsBoolean("booleanValue", true));
}
use of com.hazelcast.simulator.common.TestCase in project hazelcast-simulator by hazelcast.
the class PropertyBindingTest method loadAsDouble_nonExisting.
@Test
public void loadAsDouble_nonExisting() {
TestCase testCase = new TestCase("foo");
PropertyBinding binding = new PropertyBinding(testCase);
assertEquals(10, binding.loadAsDouble("doubleValue", 10), 0.1);
}
use of com.hazelcast.simulator.common.TestCase in project hazelcast-simulator by hazelcast.
the class PropertyBindingTest method loadAsLong_existing.
@Test
public void loadAsLong_existing() {
TestCase testCase = new TestCase("foo").setProperty("longValue", 50);
PropertyBinding binding = new PropertyBinding(testCase);
assertEquals(50, binding.loadAsLong("longValue", 10));
}
Aggregations