No commit activity in last 3 years
No release in over 3 years
A set of Capybara selectors query and interact with Angular Material Directives
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

>= 2.5.0, ~> 2.5
>= 1.6.0, ~> 1.6
>= 3.3.0, ~> 3.3
>= 1.4.6, ~> 1.4
 Project Readme

Capybara Selectors for Angular Material

Build Status Gem Version

A DSL for interacting and/or checking against Angular Material components.

This is tested using the capybara/poltergeist driver.

If you want to test how this works locally, check out this repo, install then run rackup -p8000. You'll see the paths in the app.js file. eg: localhost:8000/#/radio. I'll get around to documenting more later.

Installation

Add this line to your application's Gemfile:

gem 'capybara-angular-material'

You'll also need to install Capybara.

Usage

In your spec helper, include the DSL:

require 'capybara/angular/material'

RSpec.configure do |config|
  include Capybara::Angular::Material
end

The DSL

Querying forms

have_md_checkbox('Some text')
have_md_checkbox('Other thing', :checked => true)
have_md_button('Some text')
have_md_radio_button('Banana', :checked => true)
have_md_radio_button('Banana')
have_md_radio_button('Some place holder text')
have_md_select('Select Label')

Interacting with forms

md_check('A checkbox')
md_uncheck('A checkbox')
md_select('An option', :from => 'Select Menu')