Sha256: 76f88473ca721a30a1bca7467342eb6f349b8e06e9c9ed76cda4b4096e93c377

Contents?: true

Size: 892 Bytes

Versions: 3

Compression:

Stored size: 892 Bytes

Contents

require 'spec_helper'

describe Arachni::OptionGroups::BrowserCluster do
    include_examples 'option_group'
    subject { described_class.new }

    %w(pool_size job_timeout worker_time_to_live ignore_images screen_width
        screen_height local_storage).each do |method|
        it { is_expected.to respond_to method }
        it { is_expected.to respond_to "#{method}=" }
    end

    describe '#local_storage' do
        context 'when passed a Hash' do
            it 'sets it' do
                subject.local_storage = { 1 => 2 }
                expect(subject.local_storage).to eq({ 1 => 2 })
            end
        end

        context 'when passed anything other than Hash' do
            it 'raises ArgumentError' do
                expect do
                    subject.local_storage = 1
                end.to raise_error ArgumentError
            end
        end
    end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
arachni-1.3.2 spec/arachni/option_groups/browser_cluster_spec.rb
arachni-1.3.1 spec/arachni/option_groups/browser_cluster_spec.rb
arachni-1.3 spec/arachni/option_groups/browser_cluster_spec.rb