inspec/test/fixtures/profiles/old-examples/custom-resource/libraries/example.rb
Ryan Davis db8e6e7415 Moved test/unit/mock/* to test/fixtures
Signed-off-by: Ryan Davis <zenspider@chef.io>
2019-11-08 16:29:03 -08:00

20 lines
364 B
Ruby

class Example < Inspec.resource(1)
name 'example'
example "
describe example do
its('crime_rate') { should be < 2 }
it { should have_a_fabulous_mustache }
end
"
def crime_rate
# call out ot another custom resource
inspec.batsignal.number_of_sightings
end
def has_a_fabulous_mustache?
# always true
true
end
end