Sha256: 9290d3168812b70fc649d276e17f5a426f62ee1d25e8598d0eb3de9755f7eb96

Contents?: true

Size: 738 Bytes

Versions: 91

Compression:

Stored size: 738 Bytes

Contents

require 'spec_helper'
require 'puppet/module_tool'

describe Puppet::ModuleTool::Applications::Application do
  describe 'app' do

    good_versions = %w{ 1.2.4 0.0.1 0.0.0 0.0.2-git-8-g3d316d1 0.0.3-b1 10.100.10000
                         0.1.2-rc1 0.1.2-dev-1 0.1.2-svn12345 0.1.2-3 }
    bad_versions = %w{ 0.1 0 0.1.2.3 dev 0.1.2beta }

    let :app do Class.new(described_class).new end

    good_versions.each do |ver|
      it "should accept version string #{ver}" do
        app.parse_filename("puppetlabs-ntp-#{ver}")
      end
    end

    bad_versions.each do |ver|
      it "should not accept version string #{ver}" do
        expect { app.parse_filename("puppetlabs-ntp-#{ver}") }.to raise_error
      end
    end
  end
end

Version data entries

91 entries across 91 versions & 1 rubygems

Version Path
puppet-3.7.3-x86-mingw32 spec/unit/module_tool/application_spec.rb
puppet-3.7.3-x64-mingw32 spec/unit/module_tool/application_spec.rb
puppet-3.7.2 spec/unit/module_tool/application_spec.rb
puppet-3.7.2-x86-mingw32 spec/unit/module_tool/application_spec.rb
puppet-3.7.2-x64-mingw32 spec/unit/module_tool/application_spec.rb
puppet-3.7.1 spec/unit/module_tool/application_spec.rb
puppet-3.7.1-x86-mingw32 spec/unit/module_tool/application_spec.rb
puppet-3.7.1-x64-mingw32 spec/unit/module_tool/application_spec.rb
puppet-3.7.0 spec/unit/module_tool/application_spec.rb
puppet-3.7.0-x86-mingw32 spec/unit/module_tool/application_spec.rb
puppet-3.7.0-x64-mingw32 spec/unit/module_tool/application_spec.rb
puppet-3.6.2 spec/unit/module_tool/application_spec.rb
puppet-3.6.2-x86-mingw32 spec/unit/module_tool/application_spec.rb
puppet-3.6.1 spec/unit/module_tool/application_spec.rb
puppet-3.6.1-x86-mingw32 spec/unit/module_tool/application_spec.rb
puppet-3.6.0 spec/unit/module_tool/application_spec.rb
puppet-3.6.0-x86-mingw32 spec/unit/module_tool/application_spec.rb
puppet-3.6.0.rc1 spec/unit/module_tool/application_spec.rb
puppet-3.6.0.rc1-x86-mingw32 spec/unit/module_tool/application_spec.rb
puppet-3.5.1 spec/unit/module_tool/application_spec.rb