test/unit/resources/file_test.rb in inspec-0.20.0 vs test/unit/resources/file_test.rb in inspec-0.20.1
- old
+ new
@@ -31,9 +31,16 @@
describe '#executable?' do
shared_file_permission_tests(:executable?)
end
+ describe '#basename' do
+ it 'returns the basename' do
+ resource.stubs(:basename).returns('fakefile')
+ resource.basename.must_equal('fakefile')
+ end
+ end
+
describe '#to_s' do
it 'returns a properly formatted string' do
resource.to_s.must_equal('File /fakepath/fakefile')
end
end