Closed sourrust closed 13 years ago
Thanks, man. Must have goofed a refactor...
Can you write a test that demonstrates the issue in the second commit?
On Aug 29, 2011, at 6:17 PM, sourrustreply@reply.github.com wrote:
H, M and L where calling an array that didn't exist.
Reply to this email directly or view it on GitHub: https://github.com/misfo/jim/pull/22
For when M got a decimal or when lastFullyVisibleRow returns more rows than there are lines? Or both?
I keep getting back a no method error when testing for M
Ace: motions: M (1, 0, 1)Rerun
Died on test #1: Object [object Object] has no method 'getFirstFullyVisibleRow' - {}
My best guess is that the tests never renders ace, so there isn't a getFirstFullyVisibleRow or getLastFullyVisibleRow method.
However, both are pretty easy to replicate:
lastFullyVIsibleRow
Without any changes
jim.adaptor.lastFullyVisibleRow()
For my case I would get back 42 when it should only be 16
decimal
With changes, but minus Math.floor
You end up at the beginning line 9 instead of on the first non-blank character on line 8
We're gonna have to mock a few of those viewport-related methods on the renderer. I'll write some tests for H
, M
, and L
(my bad, should have wrote them on the first go round) that will mock out those methods...
Thanks again for spotting these
I wrote some tests for H
, M
, and L
and exposed @renderer
to the tests:
https://github.com/misfo/jim/commit/4abcb387dc81057c21704651efaeebcd18e62fa1#L1R46
So it's will be easy peasy to mock out renderer methods now. Thanks for the pull
H, M and L where calling an array that didn't exist.