Package com.vaadin.flow.component.html
Class RangeInputTester
-
- All Implemented Interfaces:
-
com.vaadin.browserless.Clickable
public class RangeInputTester extends ComponentTester<RangeInput>
- Since:
1.0
-
-
Constructor Summary
Constructors Constructor Description RangeInputTester(RangeInput component)Wrap given component for testing.
-
Method Summary
Modifier and Type Method Description DoublegetValue()Get the current value of the component. voidsetValue(Double value)Set the value to the component if it is usable. voidincrease()Increase the value by the amount defined by component step. voidincrease(int times)Increases the value by a specified multiple of the component step setting. voiddecrease()Decreases the value by the amount defined by component step. voiddecrease(int times)Decreases the value by a specified multiple of the component step setting. -
Methods inherited from class com.vaadin.browserless.ComponentTester
ensureComponentIsUsable, find, getComponent, isUsable, setModal -
Methods inherited from class com.vaadin.browserless.Clickable
click, click, click, middleClick, middleClick, rightClick, rightClick -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
setValue
void setValue(Double value)
Set the value to the component if it is usable.
For a non interactable component an IllegalStateException will be thrown as the end user would not be able to set a value.
The value must be in the component min - max range, and should be valid according to the step scale factor, otherwise an IllegalArgumentException is thrown.- Parameters:
value- value to set
-
increase
void increase()
Increase the value by the amount defined by component step.
If the step is not defined, an IllegalStateException is thrown. An IllegalArgumentException is thrown if increase operation exceeds the max boundaries.
-
increase
void increase(int times)
Increases the value by a specified multiple of the component step setting.
If the step is not defined, an IllegalStateException is thrown. An IllegalArgumentException is thrown if increase operation exceeds the max boundaries.- Parameters:
times- The number of times the component step value should be multiplied before adding to the component value.
-
decrease
void decrease()
Decreases the value by the amount defined by component step.
If the step is not defined, an IllegalStateException is thrown. An IllegalArgumentException is thrown if increase operation exceeds the min boundaries.
-
decrease
void decrease(int times)
Decreases the value by a specified multiple of the component step setting.
If the step is not defined, an IllegalStateException is thrown. An IllegalArgumentException is thrown if increase operation exceeds the min boundaries.- Parameters:
times- The number of times the component step value should be multiplied before subtracting from the component value.
-
-
-
-