Sha256: b43ff680240eeef60204a0e307930cff91be045285c1f17c330b6631d1366e48

Contents?: true

Size: 845 Bytes

Versions: 4

Compression:

Stored size: 845 Bytes

Contents

require File.expand_path(File.dirname(__FILE__) + '/../spec_helper')

describe Autogui do

  before(:each) do
    @filename = 'input.txt'
    write_file(@filename, "the quick brown fox")
  end

  describe 'Aruba::API.current_dir' do

    it "should return the current dir as 'tmp/aruba'" do
      current_dir.should match(/^tmp\/aruba$/)
    end
  end

  describe "aruba_helper fullpath('input.txt')" do

    it "should return a valid expanded path to 'input.txt'" do
      path = fullpath('input.txt')
      path.should match(/tmp..*aruba/)
      File.exists?(path).should == true
    end
  end

  describe "aruba_helper get_file_contents('input.txt')" do

    it "should return the contents of 'input.txt' as a String" do
      get_file_contents('input.txt').should == 'the quick brown fox'
    end
  end

end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
win32-autogui-0.5.3 spec/basic_gem/aruba_helper_spec.rb
win32-autogui-0.5.2 spec/basic_gem/aruba_helper_spec.rb
win32-autogui-0.5.1 spec/basic_gem/aruba_helper_spec.rb
win32-autogui-0.5.0 spec/basic_gem/aruba_helper_spec.rb