mirror of
https://github.com/pulsar-edit/pulsar.git
synced 2024-11-14 04:29:04 +03:00
11 lines
500 B
CoffeeScript
11 lines
500 B
CoffeeScript
describe "Pasteboard", ->
|
|
describe "write(text, metadata) and read()", ->
|
|
it "writes and reads text to/from the native pasteboard", ->
|
|
expect(pasteboard.read()).toEqual ['initial pasteboard content']
|
|
pasteboard.write('next')
|
|
expect(pasteboard.read()[0]).toBe 'next'
|
|
|
|
it "returns metadata if the item on the native pasteboard matches the last written item", ->
|
|
pasteboard.write('next', {meta: 'data'})
|
|
expect(pasteboard.read()).toEqual ['next', {meta: 'data'}]
|