Sha256: 204068fe1db60801c77f2ccc2a00b3257bbd619bde4111bb3abe6c846f0aca42

Contents?: true

Size: 566 Bytes

Versions: 9

Compression:

Stored size: 566 Bytes

Contents

require 'spec_helper'

describe LinuxAdmin::Package do
  describe "#info" do
    it "dispatches to redhat lookup mechanism" do
      LinuxAdmin::Distro.should_receive(:local).and_return(LinuxAdmin::Distros.redhat)
      LinuxAdmin::Rpm.should_receive(:info).with('ruby')
      described_class.info 'ruby'
    end

    it "dispatches to ubuntu lookup mechanism" do
      LinuxAdmin::Distro.should_receive(:local).twice.and_return(LinuxAdmin::Distros.ubuntu)
      LinuxAdmin::Deb.should_receive(:info).with('ruby')
      described_class.info 'ruby'
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
linux_admin-0.8.0 spec/package_spec.rb
linux_admin-0.7.0 spec/package_spec.rb
linux_admin-0.6.0 spec/package_spec.rb
linux_admin-0.5.7 spec/package_spec.rb
linux_admin-0.5.6 spec/package_spec.rb
linux_admin-0.5.5 spec/package_spec.rb
linux_admin-0.5.4 spec/package_spec.rb
linux_admin-0.5.3 spec/package_spec.rb
linux_admin-0.5.2 spec/package_spec.rb