]> source.dussan.org Git - vaadin-framework.git/commitdiff
Removed extra IntegerValidator for a field with an Integer property data
authorArtur Signell <artur@vaadin.com>
Thu, 15 Dec 2011 10:27:17 +0000 (12:27 +0200)
committerArtur Signell <artur@vaadin.com>
Thu, 15 Dec 2011 10:32:54 +0000 (12:32 +0200)
source. Corrected assertion in the test as converter throws the
exception and not an IntegerValidator anymore

tests/testbench/com/vaadin/tests/components/datefield/CommitInvalid.html
tests/testbench/com/vaadin/tests/components/datefield/CommitInvalid.java

index 29ad93c6c6b9a4c68d2a4e47effaff8687110ca9..b033a4c9e0aabac128494541e134011e20fe7a42 100644 (file)
 <tr>
        <td>assertText</td>
        <td>vaadin=runcomvaadintestscomponentsdatefieldCommitInvalid::PID_SLog_row_2</td>
-       <td>4. Commit failed : Not an integer</td>
+       <td>4. Commit failed : Could not convert '42f' to java.lang.Integer</td>
 </tr>
 <tr>
        <td>assertText</td>
        <td>vaadin=runcomvaadintestscomponentsdatefieldCommitInvalid::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VForm[0]/domChild[0]/domChild[2]/domChild[0]</td>
-       <td>Not an integer</td>
+       <td>Could not convert '42f' to java.lang.Integer</td>
 </tr>
 <tr>
        <td>assertText</td>
index 36ee068af4665e32348d1062e72465bcb24348da..1395b4d73562eaf26c0dc4659c069637b27260ec 100644 (file)
@@ -6,7 +6,6 @@ import java.util.Locale;
 
 import com.vaadin.data.Validator.InvalidValueException;
 import com.vaadin.data.util.ObjectProperty;
-import com.vaadin.data.validator.IntegerValidator;
 import com.vaadin.tests.components.TestBase;
 import com.vaadin.tests.util.Log;
 import com.vaadin.ui.Button;
@@ -64,7 +63,6 @@ public class CommitInvalid extends TestBase {
          */
         integerProperty = new ObjectProperty<Integer>(42);
         integerField = new TextField("Another Field", integerProperty);
-        integerField.addValidator(new IntegerValidator("Not an integer"));
         integerField.setDebugId("_IF");
         form.addField("text", integerField);