This file is indexed.

/usr/lib/ruby/vendor_ruby/aruba/matchers/path/be_an_existing_path.rb is in ruby-aruba 0.14.2-2.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
require 'rspec/expectations/version'

# @!method be_an_existing_path
#   This matchers checks if <path> exists in filesystem
#
#   @return [TrueClass, FalseClass] The result
#
#     false:
#     * if path does not exist
#     true:
#     * if path exists
#
#   @example Use matcher
#
#     RSpec.describe do
#       it { expect(file).to be_an_existing_path }
#       it { expect(directory).to be_an_existing_path }
#       it { expect(all_directories).to all be_an_existing_path }
#       it { expect(all_directories).to include an_existing_path }
#     end
RSpec::Matchers.define :be_an_existing_path do |_|
  match do |actual|
    exist?(actual)
  end

  failure_message do |actual|
    format("expected that path \"%s\" exists", actual)
  end

  failure_message_when_negated do |actual|
    format("expected that path \"%s\" does not exist", actual)
  end
end

if RSpec::Expectations::Version::STRING >= '3.0'
  RSpec::Matchers.alias_matcher :an_existing_path, :be_an_existing_path
end