Sha256: 4e75bc689ce3275e1ae9e579cee730e7a2e1a997acf0ee5bc22bf756fb83cb3c

Contents?: true

Size: 579 Bytes

Versions: 1

Compression:

Stored size: 579 Bytes

Contents

require 'spec_helper'

describe HashValidator::Validator::Base do
  let(:validator) { HashValidator::Validator::Base.new }

  describe '#should_validate?' do
    it 'throws an exception' do
      expect { validator.should_validate?('name') }.to raise_error(StandardError, 'should_validate? should not be called directly on BaseValidator')
    end
  end

  describe '#validate' do
    it 'throws an exception' do
      expect { validator.validate('key', 'value', {}, {}) }.to raise_error(StandardError, 'validate should not be called directly on BaseValidator')
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
hash_validator-0.1.0 spec/validators/base_spec.rb