Sha256: d64daa5448032e1a037b9c854308a70784fc7cace5c13ab51f8e3cfa059e697a

Contents?: true

Size: 539 Bytes

Versions: 3

Compression:

Stored size: 539 Bytes

Contents

# encoding: utf-8

require 'spec_helper'

describe Yardstick::Measurement, 'skip?' do
  subject { described_class.new(rule).skip? }

  let(:document) { DocumentMock.new }

  context 'when rule is enabled' do
    let(:rule) { ValidRule.new(document) }

    it { should be(false) }
  end

  context 'when rule is not validatable' do
    let(:rule) { NotValidatableRule.new(document) }

    it { should be(true) }
  end

  context 'when rule is disabled' do
    let(:rule) { DisabledRule.new(document) }

    it { should be(true) }
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
yardstick-0.9.9 spec/unit/yardstick/measurement/skip_predicate_spec.rb
yardstick-0.9.8 spec/unit/yardstick/measurement/skip_predicate_spec.rb
yardstick-0.9.7 spec/unit/yardstick/measurement/skip_predicate_spec.rb