Sha256: ba02ebd4a2fa0f21ae9d6ccfbc5a7a3d0edd25eb0ce9ea49158fad4f9d896a14
Contents?: true
Size: 1.17 KB
Versions: 6
Compression:
Stored size: 1.17 KB
Contents
#--- # Excerpted from "Scripted GUI Testing With Ruby", # published by The Pragmatic Bookshelf. # Copyrights apply to this code. It may not be used to create training material, # courses, books, articles, and the like. Contact us if you are in doubt. # We make no guarantees that this code is fit for any purpose. # Visit http://www.pragmaticprogrammer.com/titles/idgtr for more book information. #--- require 'spec_helper' describe 'The editor' do it_should_behave_like 'a new document' it 'supports multiple levels of undo' do @note.text = 'abc' @note.text = 'def' @note.undo @note.text.should == 'abc' @note.undo @note.text.should be_empty end it 'supports copying and pasting text' do @note.text = 'itchy' @note.select_all @note.copy @note.text.should == 'itchy' @note.text = 'scratchy' @note.select_all @note.paste @note.text.should == 'itchy' end it 'supports cutting and pasting text' do @note.text = 'pineapple' @note.select_all @note.cut @note.text.should be_empty @note.text = 'mango' @note.select_all @note.paste @note.text.should == 'pineapple' end end
Version data entries
6 entries across 6 versions & 1 rubygems