Sha256: 66de26cfcc2748447c1b046bf5a2d6ce8ea36a73e8350d8f60b0b48565b1e43f
Contents?: true
Size: 731 Bytes
Versions: 66
Compression:
Stored size: 731 Bytes
Contents
require 'spec_helper' require 'specinfra/helper/detect_os/esxi' describe Specinfra::Helper::DetectOs::Esxi do it 'Should return esxi when esxi is installed.' do allow(Specinfra::Helper::DetectOs::Esxi).to receive(:run_command) { CommandResult.new(:stdout => 'VMware ESXi 5.0.0 build-123445', :exit_status => 0) } expect(Specinfra::Helper::DetectOs::Esxi.detect).to include(:family => 'esxi', :release => '5.0.0 build-123445') end it 'Should not return esxi when VMware Workstation is installed.' do allow(Specinfra::Helper::DetectOs::Esxi).to receive(:run_command) { CommandResult.new(:stdout => 'VMware Workstation', :exit_status => 0) } expect(Specinfra::Helper::DetectOs::Esxi.detect).to be_nil end end
Version data entries
66 entries across 66 versions & 1 rubygems