Project

dropybara

0.01
No commit activity in last 3 years
No release in over 3 years
Drag and drop files in Capybara
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies
 Project Readme

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'))