Test fixes

Signed-off-by: Nikita Mathur <nikita.mathur@chef.io>
This commit is contained in:
Nikita Mathur 2021-12-22 13:48:05 +05:30
parent b0794c2262
commit d1cee33462
3 changed files with 4 additions and 4 deletions

View file

@ -1,3 +1,3 @@
Name Version Source ProviderName
---- ------- ------ ------------
Chef Client 17.8.25 Programs
Chef Client 12.12.15.1 Programs

View file

@ -241,7 +241,7 @@ class MockLoader
"dpkg -s held-package" => cmd.call("dpkg-s-held-package"),
"rpm -qi curl" => cmd.call("rpm-qi-curl"),
"yum list curl" => cmd.call("yum-list-curl"),
"Get-Package Chef Client -AllVersions" => cmd.call("get-pkg-versions"),
"Get-Package Chef Client v12.12.15 -AllVersions" => cmd.call("get-pkg-versions"),
"rpm -qi --dbpath /var/lib/fake_rpmdb curl" => cmd.call("rpm-qi-curl"),
"rpm -qi --dbpath /var/lib/rpmdb_does_not_exist curl" => cmd_exit_1.call,
"pacman -Qi curl" => cmd.call("pacman-qi-curl"),

View file

@ -50,7 +50,7 @@ describe "Inspec::Resources::Package" do
installed: true,
version: "7.29.0-19.el7",
type: "rpm",
only_version_no: "7.29.0"
only_version_no: "7.29.0",
}
end
@ -108,7 +108,7 @@ describe "Inspec::Resources::Package" do
_(resource.installed?).must_equal true
_(resource.version).must_equal "12.12.15.1"
_(resource.info).must_equal pkg
_(resource.latest?).must_equal false
_(resource.latest?).must_equal true
end
# solaris 10