diff options
Diffstat (limited to 'src/com/vaadin/tests/components/datefield/DateFieldReadOnly.java')
-rw-r--r-- | src/com/vaadin/tests/components/datefield/DateFieldReadOnly.java | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/com/vaadin/tests/components/datefield/DateFieldReadOnly.java b/src/com/vaadin/tests/components/datefield/DateFieldReadOnly.java index 857af3a8be..46af5b07be 100644 --- a/src/com/vaadin/tests/components/datefield/DateFieldReadOnly.java +++ b/src/com/vaadin/tests/components/datefield/DateFieldReadOnly.java @@ -30,7 +30,11 @@ public class DateFieldReadOnly extends TestBase { timeField.setWidth("8em");
timeField.addStyleName("timeField");
- timeField.setValue(new Date());
+ // Set date so that testing always has same time
+ Date date = new Date();
+ date.setTime((long) 1000000000000.0);
+
+ timeField.setValue(date);
timeField.setReadOnly(true);
addComponent(timeField);
|