Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/perl-weasel/pherkin-extension-weasel
Extension for Test::BDD::Cucumber providing Weasel access
https://github.com/perl-weasel/pherkin-extension-weasel
bdd behavior-driven-development cucumber perl testing weasel web-app web-application webapp
Last synced: 10 days ago
JSON representation
Extension for Test::BDD::Cucumber providing Weasel access
- Host: GitHub
- URL: https://github.com/perl-weasel/pherkin-extension-weasel
- Owner: perl-weasel
- Created: 2016-02-16T10:15:16.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2023-08-11T22:38:06.000Z (over 1 year ago)
- Last Synced: 2024-11-15T22:18:19.894Z (2 months ago)
- Topics: bdd, behavior-driven-development, cucumber, perl, testing, weasel, web-app, web-application, webapp
- Language: Perl
- Homepage:
- Size: 85 KB
- Stars: 1
- Watchers: 3
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGES
Awesome Lists containing this project
README
# NAME
Pherkin::Extension::Weasel - Pherkin extension for web-testing
[![Build Status](https://travis-ci.org/perl-weasel/pherkin-extension-weasel.svg?branch=master)](https://travis-ci.org/perl-weasel/pherkin-extension-weasel)
# VERSION
0.16
# SYNOPSIS
```yaml
# In the pherkin config file t/.pherkin.yaml:
default:
extensions:
Pherkin::Extension::Weasel:
default_session: selenium
sessions:
selenium:
# write screenshots to img/
screenshots_dir: img
screenshot_events:
timestamps: 0
# generate screenshots before every step
pre_step: 1
# and at the end of every scenario
post_scenario: 1
base_url: http://localhost:5000
driver:
drv_name: Weasel::Driver::Selenium2
wait_timeout: 3000
window_size: 1024x1280
caps:
port: 4420
``````perl
# Which makes the S->{ext_wsl} field available,
# pointing at the default session, in steps of features or scenarios
# marked with the '@weasel' tag so in the steps you can use:use Weasel::FindExpanders::HTML;
Then qr/I see an input element with label XYZ/, sub {
S->{ext_wsl}->page->find('*labelled', text => 'XYZ');
};
```
# DESCRIPTIONThis module implements an extension to [Test::BDD::Cucumber
(aka pherkin)](https://github.com/pjlsergeant/test-bdd-cucumber-perl),
providing access to a
[`Weasel::Session`](https://github.com/perl-weasel/weasel/) and the
following features:* Starting sessions for scenarios which need it
* Taking screenshots on configured events
* Provide basic steps for
* Page navigation
* Page content assertionIntended features to be implemented:
* Browser session transcript recording, annotating browser
manipulation invocations with Weasel function return
values and screenshots.(More ideas welcome, please log issues.)
# INSTALLATION
```sh
# Install Pherkin::Extension::Weasel with its dependencies
$ cpanm Pherkin::Extension::Weasel# Install the (currently only) Weasel web driver
$ cpanm Weasel::Driver::Selenium2
```If you want to use the Dojo compatibility widgets, also:
```sh
cpanm Weasel::Widgets::Dojo
```# SUPPORT
## BUGS
Bugs can be filed in the GitHub issue tracker for the Weasel project:
https://github.com/perl-weasel/pherkin-extension-weasel/issues## DISCUSSION
Community support is available through
[[email protected]](mailto:[email protected]).# COPYRIGHT
```
Copyright (c) 2016-2018 Erik Huelsmann
```# LICENSE
Same as Perl