Skip to content

Latest commit

 

History

History
39 lines (26 loc) · 1.22 KB

README.md

File metadata and controls

39 lines (26 loc) · 1.22 KB

Dropybara

License Gem Version Build Status Codacy Badge codecov

This adds file drag and drop functionality to Capybara

No jQuery required

Installation

Add to your Gemfile:

gem 'dropybara'

Then bundle install

Require it in your tests setup:

require 'dropybara'

Usage

It takes similar arguments to attach_file

page.drop_file(css_locator, path, *args)

This uses attach_file under the hood, as such path and *args are passed directly to it.

Example

page.drop_file('.drop-box', File.expand_path('upload.txt'))