mirror of
https://github.com/inspec/inspec
synced 2024-11-23 13:13:22 +00:00
c5a66f58a6
Signed-off-by: Sonu Saha <sonu.saha@progress.com>
18 lines
653 B
Ruby
18 lines
653 B
Ruby
# If we can load the InSpec globals definition file...
|
|
require "inspec/globals"
|
|
# ... we can find the core test unit helper file
|
|
require "#{Inspec.src_root}/test/helper"
|
|
|
|
# Load (require) the resource library file
|
|
require_relative "../../../lib/inspec/resources/cgroup"
|
|
|
|
describe Inspec::Resources::Cgroup do
|
|
it "works correctly with the constructor on the platform" do
|
|
# Add contructor arguments to load_resource if needed
|
|
resource = MockLoader.new("linux".to_sym).load_resource("cgroup")
|
|
|
|
_(resource.has_bells?).must_equal true
|
|
_(resource.shoe_size).must_equal 42
|
|
_(resource.resource_id).must_equal "something special"
|
|
end
|
|
end
|