Sha256: 2ebfe4118aa4036e04fc92e77153a434ab0c36c7e729d6e9198224c7b7e7e4f3

Contents?: true

Size: 1.01 KB

Versions: 76

Compression:

Stored size: 1.01 KB

Contents

require 'spec_helper'

describe Puppet::Type.type(:package).provider(:pip3) do

  it { is_expected.to be_installable }
  it { is_expected.to be_uninstallable }
  it { is_expected.to be_upgradeable }
  it { is_expected.to be_versionable }
  it { is_expected.to be_install_options }
  it { is_expected.to be_targetable }

  it "should inherit most things from pip provider" do
    expect(described_class < Puppet::Type.type(:package).provider(:pip))
  end

  it "should use pip3 command" do
    expect(described_class.cmd).to eq(["pip3"])
  end

  context 'calculated specificity' do
    include_context 'provider specificity'

    context 'when is not defaultfor' do
      subject { described_class.specificity }
      it { is_expected.to eql 1 }
    end

    context 'when is defaultfor' do
      let(:os) { Puppet.runtime[:facter].value(:operatingsystem) }
      subject do
        described_class.defaultfor(operatingsystem: os)
        described_class.specificity
      end
      it { is_expected.to be > 100 }
    end
  end

end

Version data entries

76 entries across 76 versions & 1 rubygems

Version Path
puppet-7.18.0 spec/unit/provider/package/pip3_spec.rb
puppet-7.18.0-x86-mingw32 spec/unit/provider/package/pip3_spec.rb
puppet-7.18.0-x64-mingw32 spec/unit/provider/package/pip3_spec.rb
puppet-7.18.0-universal-darwin spec/unit/provider/package/pip3_spec.rb
puppet-7.17.0 spec/unit/provider/package/pip3_spec.rb
puppet-7.17.0-x86-mingw32 spec/unit/provider/package/pip3_spec.rb
puppet-7.17.0-x64-mingw32 spec/unit/provider/package/pip3_spec.rb
puppet-7.17.0-universal-darwin spec/unit/provider/package/pip3_spec.rb
puppet-7.16.0 spec/unit/provider/package/pip3_spec.rb
puppet-7.16.0-x86-mingw32 spec/unit/provider/package/pip3_spec.rb
puppet-7.16.0-x64-mingw32 spec/unit/provider/package/pip3_spec.rb
puppet-7.16.0-universal-darwin spec/unit/provider/package/pip3_spec.rb
puppet-7.15.0 spec/unit/provider/package/pip3_spec.rb
puppet-7.15.0-x86-mingw32 spec/unit/provider/package/pip3_spec.rb
puppet-7.15.0-x64-mingw32 spec/unit/provider/package/pip3_spec.rb
puppet-7.15.0-universal-darwin spec/unit/provider/package/pip3_spec.rb
puppet-7.14.0 spec/unit/provider/package/pip3_spec.rb
puppet-7.14.0-x86-mingw32 spec/unit/provider/package/pip3_spec.rb
puppet-7.14.0-x64-mingw32 spec/unit/provider/package/pip3_spec.rb
puppet-7.14.0-universal-darwin spec/unit/provider/package/pip3_spec.rb