Sha256: 4ddde21e94dbc8c99b797f1be1021a9edeca9d41c97f128e86c8f65ef39971af

Contents?: true

Size: 593 Bytes

Versions: 28

Compression:

Stored size: 593 Bytes

Contents

#!/usr/bin/env rspec
require 'spec_helper'
require 'mcollective/validator/ipv6address_validator'

module MCollective
  module Validator
    describe "#validate" do
      it "should raise an exception if the supplied value is not an ipv6 address" do
        expect{
          Ipv6addressValidator.validate("foobar")
        }.to raise_error(ValidatorError, "value should be an ipv6 address")
      end

      it "should not raise an exception if the supplied value is an ipv6 address" do
        Ipv6addressValidator.validate("2001:db8:85a3:8d3:1319:8a2e:370:7348")
      end
    end
  end
end

Version data entries

28 entries across 28 versions & 1 rubygems

Version Path
mcollective-client-2.9.1 spec/unit/mcollective/validator/ipv6address_validator_spec.rb
mcollective-client-2.9.0 spec/unit/mcollective/validator/ipv6address_validator_spec.rb
mcollective-client-2.8.9 spec/unit/mcollective/validator/ipv6address_validator_spec.rb
mcollective-client-2.8.4 spec/unit/mcollective/validator/ipv6address_validator_spec.rb
mcollective-client-2.8.3 spec/unit/mcollective/validator/ipv6address_validator_spec.rb
mcollective-client-2.8.2 spec/unit/mcollective/validator/ipv6address_validator_spec.rb
mcollective-client-2.8.1 spec/unit/mcollective/validator/ipv6address_validator_spec.rb
mcollective-client-2.8.0 spec/unit/mcollective/validator/ipv6address_validator_spec.rb