Skip to content

Commit

Permalink
chore: remove commented lines
Browse files Browse the repository at this point in the history
  • Loading branch information
manolo committed Nov 13, 2020
1 parent 4b06c47 commit f9fcfd3
Showing 1 changed file with 0 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,6 @@ public void testValueChangeModesForBigDecimalField()
private void testValueChangeModes(WebElement field, String componentName)
throws InterruptedException {

long last = System.currentTimeMillis();

field.sendKeys("1");
assertMessageNotUpdated(
"By default the value change events should not be sent on every key stroke (ValueChangeMode should be ON_CHANGE)");
Expand All @@ -122,18 +120,13 @@ private void testValueChangeModes(WebElement field, String componentName)
// "committing" the change and firing a change-event.
field.sendKeys(Keys.ENTER);
waitUntilMessageUpdated();
// assertTrue("By default the value change events should be sent when clicking enter (ValueChangeMode should be ON_CHANGE)",
// -last + (last = System.currentTimeMillis()) < 1000);
}

field.sendKeys("1");
assertMessageNotUpdated(
"By default the value change events should not be sent on every key stroke (ValueChangeMode should be ON_CHANGE)");
blur();
waitUntilMessageUpdated();
// assertTrue("The value change events should be sent on blur",
// -last + (last = System.currentTimeMillis()) < 1000);


clickButton(componentName + "-on-blur");

Expand All @@ -147,15 +140,11 @@ private void testValueChangeModes(WebElement field, String componentName)

blur();
waitUntilMessageUpdated();
// assertTrue("The value change events should be sent on blur when using ValueChangeMode.ON_BLUR",
// -last + (last = System.currentTimeMillis()) < 1000);

clickButton(componentName + "-eager");
field.sendKeys("1");

waitUntilMessageUpdated();
// assertTrue("The value change events should be sent on every key stroke when using ValueChangeMode.EAGER",
// -last + (last = System.currentTimeMillis()) < 1000);

blur();
assertMessageNotUpdated(
Expand Down Expand Up @@ -193,9 +182,6 @@ private void testValueChangeTimeout(WebElement field, String componentName)
clickButton(componentName + "-timeout");
field.sendKeys("1");
waitUntilMessageUpdated();
// assertTrue("The value change event should be sent on first key stroke when using ValueChangeMode.TIMEOUT",
// -last + (last = System.currentTimeMillis()) < 1000);


field.sendKeys("1");
assertMessageNotUpdated(
Expand All @@ -214,7 +200,6 @@ private void assertMessageNotUpdated(String failMessage) {
Assert.assertFalse(failMessage, isMessageUpdated());
}

int count = 0;
private boolean isMessageUpdated() {
String messageText = message.getText();
boolean isUpdated = !message.getText().equals(lastMessageText);
Expand Down

0 comments on commit f9fcfd3

Please sign in to comment.