jonleighton/poltergeist — pull request #421 by jhawthorn (2013-12-02 02:59:09+00:00)
Title: Entering negatives into an <input type="number">

When entering a negative number into a value field. The absolute value would instead be set. This is because values are entered char-by-char and '-' by itself wasn't considered a valid value.

This modifies PoltergeistAgent.Node.set to set the entire value at once for an input type=number. Number fields aren't necessarily set via keypresses anyways (they have those little buttons).

This change may be unnecessary if native keyboard events are used again (landed in c7ba561, reverted in 70304cc).

Also worth noting that capybara-webkit used to have this same issue thoughtbot/capybara-webkit#384