Sha256: 546c576cf7b352ba276b079d4c220d20e1f812f4f2dcb6d03328700b4669a6e1

Contents?: true

Size: 825 Bytes

Versions: 11

Compression:

Stored size: 825 Bytes

Contents

#!/usr/bin/env ruby
require File.expand_path(File.join(File.dirname(__FILE__), '../../spec_helper'))

require 'puppet/parameter/path'

[false, true].each do |arrays|
  describe "Puppet::Parameter::Path with arrays #{arrays}" do
    it_should_behave_like "all path parameters", :path, :array => arrays do
      # The new type allows us a test that is guaranteed to go direct to our
      # validation code, without passing through any "real type" overrides or
      # whatever on the way.
      Puppet::newtype(:test_puppet_parameter_path) do
        newparam(:path, :parent => Puppet::Parameter::Path, :arrays => arrays) do
          isnamevar
          accept_arrays arrays
        end
      end

      def instance(path)
        Puppet::Type.type(:test_puppet_parameter_path).new(:path => path)
      end
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
puppet-2.6.18 spec/unit/parameter/path_spec.rb
puppet-2.6.17 spec/unit/parameter/path_spec.rb
puppet-2.6.16 spec/unit/parameter/path_spec.rb
puppet-2.6.15 spec/unit/parameter/path_spec.rb
puppet-2.6.14 spec/unit/parameter/path_spec.rb
puppet-2.6.13 spec/unit/parameter/path_spec.rb
puppet-2.6.12 spec/unit/parameter/path_spec.rb
puppet-2.6.11 spec/unit/parameter/path_spec.rb
puppet-2.6.10 spec/unit/parameter/path_spec.rb
puppet-2.6.9 spec/unit/parameter/path_spec.rb
puppet-2.6.8 spec/unit/parameter/path_spec.rb