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.3.0 spec/unit/module_tool/application_spec.rb
puppet-3.3.0.rc3 spec/unit/module_tool/application_spec.rb
puppet-3.3.0.rc2 spec/unit/module_tool/application_spec.rb
puppet-3.2.4 spec/unit/module_tool/application_spec.rb
puppet-3.2.3 spec/unit/module_tool/application_spec.rb
puppet-3.2.3.rc1 spec/unit/module_tool/application_spec.rb
puppet-3.2.2 spec/unit/module_tool/application_spec.rb
puppet-3.2.1 spec/unit/module_tool/application_spec.rb
puppet-3.2.1.rc1 spec/unit/module_tool/application_spec.rb
puppet-3.2.0.rc2 spec/unit/module_tool/application_spec.rb
puppet-3.2.0.rc1 spec/unit/module_tool/application_spec.rb