Bug 917630 - Allow unlimited keypresses when on a call

On Fri, Jun 13, 2014 at 5:47 AM, Etienne Segonzac <notifications@github.com>
wrote:

> In apps/communications/dialer/test/unit/keypad_test.js:
>
> > +              value: null
> > +            }
> > +          },
> > +        stopPropagation: function() {},
> > +        type: null
> > +        };
> > +
> > +        subject._phoneNumber = '';
> > +        for (var i = 0, end = digits.length; i < end; i++) {
> > +          fakeEvent.target.dataset.value = digits.charAt(i);
> > +          fakeEvent.type = 'touchstart'
> > +          subject.keyHandler(fakeEvent);
> > +          fakeEvent.type = 'touchend'
> > +          subject.keyHandler(fakeEvent);
> > +        }
> > +        assert.equal(subject._phoneNumber, digits);
>
> I'd like to assert on subject.phoneNumberView.value instead of the
> internal variable
>
Hmm, when I try to use that instead of _phoneNumber, I only get the
'6666666666' number from the previous test, without my digits at all.
Looking through the code it looked like I should call
subject.fetchLastCalled() before testing subject.phoneNumberView.value, but
that didn't seem to help. Unfortunately none of the other tests use
phoneNumberView.value so I'm a bit stuck :/