Class: Aranha::Selenium::Session::Downloads

Inherits:
Object
  • Object
show all
Defined in:
lib/aranha/selenium/session/downloads.rb

Instance Method Summary collapse

Instance Method Details

#currentEnumerable<Pathname>

Returns:

  • (Enumerable<Pathname>)


10
11
12
13
14
15
16
# File 'lib/aranha/selenium/session/downloads.rb', line 10

def current
  dir.glob('**/*').select do |path|
    !::EacFs::FileInfo.new(path).open? && path.size.positive?
  rescue Errno::ENOENT
    false
  end
end

#dirPathname

Returns:

  • (Pathname)


19
20
21
# File 'lib/aranha/selenium/session/downloads.rb', line 19

def dir
  @dir ||= build_temporary_directory
end