Sha256: deb3dae145193a73c761c02402896702752fe8a750f5791c3bf895c0fe0b18de

Contents?: true

Size: 561 Bytes

Versions: 1

Compression:

Stored size: 561 Bytes

Contents

# frozen_string_literal: true

require_relative "spec_helper"

require "rbconfig"

if RbConfig::CONFIG['host_os'] =~ /mac|darwin/
  require 'clipboard/mac'

  describe "Clipboard::Mac" do
    before :all do
      Clipboard.implementation = Clipboard::Mac
    end

    it "can copy & paste" do
      Clipboard.copy('123mac')
      expect( Clipboard.paste ).to eq '123mac'
    end

    it "can clear" do
      Clipboard.copy('123mac')
      expect( Clipboard.paste ).to eq '123mac'
      Clipboard.clear
      expect( Clipboard.paste ).to eq ''
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
clipboard-2.0.0 spec/clipboard_mac_spec.rb