Sha256: fbe9e7dde95f089d40ccb0d8bdae87a67ee096a744c2171f858a465083286303

Contents?: true

Size: 546 Bytes

Versions: 2

Compression:

Stored size: 546 Bytes

Contents

require 'spec_helper'

describe Prickle::Capybara do
  let(:prickly) { Prickly.new }

  before do
    Prickle::Capybara.wait_time = nil
    prickly.visit '/'
  end

  context 'Screenshots', :javascript => true, :driver => :selenium do

    it 'can capture the screen' do
      screenshot_name = Time.now.strftime("%Y%m%d-%H.%M.%s")
      prickly.capture_screen screenshot_name
      `ls #{Prickle::Capybara.image_dir}`.should include "#{screenshot_name}"
    end

    after do
      `rm -f #{Prickle::Capybara.image_dir}/*.jpg`
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
prickle-0.1.0 spec/capybara_spec.rb
prickle-0.0.6 spec/capybara_spec.rb