mirror of
https://github.com/pulsar-edit/pulsar.git
synced 2024-11-10 18:24:09 +03:00
Update editor height change spec
This commit is contained in:
parent
9e6756ed6d
commit
c06f5911c6
@ -1271,11 +1271,16 @@ describe "EditorComponent", ->
|
||||
|
||||
describe "when the editor component is resized", ->
|
||||
it "updates the size in the editor model", ->
|
||||
spyOn(editor, 'setHeight').andCallThrough()
|
||||
originalHeight = editor.getHeight()
|
||||
fourLinesHeight = 4 * editor.getLineHeightInPixels()
|
||||
node.style.height = "#{originalHeight - fourLinesHeight}px"
|
||||
component.forceUpdate()
|
||||
expect(editor.getHeight()).not.toBe originalHeight
|
||||
|
||||
waitsFor ->
|
||||
editor.setHeight.callCount > 0
|
||||
|
||||
runs ->
|
||||
expect(editor.getHeight()).not.toBe originalHeight
|
||||
|
||||
buildMouseEvent = (type, properties...) ->
|
||||
properties = extend({bubbles: true, cancelable: true}, properties...)
|
||||
|
Loading…
Reference in New Issue
Block a user