mirror of
https://github.com/atom/atom.git
synced 2026-01-23 13:58:08 -05:00
Spy on ipc.send and make it synchronous
This commit is contained in:
@@ -2686,6 +2686,10 @@ describe "TextEditorComponent", ->
|
||||
|
||||
describe "middle mouse paste on Linux", ->
|
||||
it "pastes the previously selected text", ->
|
||||
spyOn(require('ipc'), 'send').andCallFake (eventName, selectedText) ->
|
||||
if eventName is 'write-text-to-selection-clipboard'
|
||||
require('clipboard').writeText(selectedText, 'selection')
|
||||
|
||||
atom.clipboard.write('')
|
||||
component.listenForMiddleMousePaste()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user