Sha256: 54789b2e44868795671a1fd106db96dbf5bc9034a95106cbc9266440e4ab3404
Contents?: true
Size: 1003 Bytes
Versions: 93
Compression:
Stored size: 1003 Bytes
Contents
#! /usr/bin/env ruby require 'spec_helper' describe "ps facts" do it "should return busybox style ps www on OpenWrt" do Facter.fact(:operatingsystem).stubs(:value).returns 'OpenWrt' Facter.fact(:ps).value.should == 'ps www' end [ 'FreeBSD', 'NetBSD', 'OpenBSD', 'Darwin', 'DragonFly' ].each do |os| it "should return unix style ps on operatingsystem #{os}" do Facter.fact(:operatingsystem).stubs(:value).returns os Facter.fact(:ps).value.should == 'ps auxwww' end end # Other Linux Distros should return a ps -ef [ 'RedHat', 'Debian', ].each do |os| it "should return gnu/linux style ps -ef on operatingsystem #{os}" do Facter.fact(:operatingsystem).stubs(:value).returns os Facter.fact(:ps).value.should == 'ps -ef' end end it "should return tasklist.exe on Windows" do Facter.fact(:operatingsystem).stubs(:value).returns 'windows' Facter.fact(:ps).value.should == 'tasklist.exe' end end
Version data entries
93 entries across 93 versions & 1 rubygems