Prototype of a yo generator for scaffolding an automation framework based on protractor and cucumber
This project is a work in progress.
To generate a powerful automation framework that is reusable, and will make it easier to create and execute consistent end-to-end tests
The generated project has dependencies that require Node 6.x.x or higher and NPM 3.x.x and Java 1.8.
- Installation
- Usage
- Generating an automation framework
- What gets done for you
- Available generators
- What do I get when I generate a page object
- What do I get when I generate a feature
- Linting and formatting code
- Development hints for making changes to yo e2e
BEFORE YOU INSTALL: please read the prerequisites
Coming Soon...
Coming Soon...
yo e2e
cd test
Directory tree
- test
- includes
- expected_conditions.js
- external_globals.js
- internal_globals.js
- page_objects.js
- page_objects
- support
- env.js
- hooks.js
- utilities
- util.js
- config
- e2e_framework_config.js
cucumber.conf.js
A test directory and all of the necessary files to start automation are included. A user will be able to generate a test directory and immediately start creating end-to-end tests. A structure and format are defined on how to begin.
More Coming Soon...
You can find all possible blueprints in the table below:
Scaffold | Usage |
---|---|
Page Object | yo e2e:page-object |
Feature | yo e2e:feature |
You get a default page object shell with the name of the page object you asked for following camelcase format, in the directory you asked for.
See below example:
'use strict';
function directDeposit() {
/*
You should use css selectors as your only selector method
*/
}
module.exports.directDeposit = directDeposit;
A feature gets generated with the given name and in the given file path. The feature name gets inserted in kebab case.
Coming Soon...
git clone git@github.com:gd46/yo-e2e.git
cd yo-e2e
npm link
npm link
is very similar to npm install -g
except that instead of downloading the package
from the repo, the just cloned yo-e2e/
folder becomes the global package.
Any changes to the files in the yo-e2e/
folder will immediately affect the global yo-e2e
package,
allowing you to quickly test any changes you make to the cli project.
Open a different tab or window, Now you can use yo-e2e
via the command line:
yo e2e
cd test
Please read the official npm-link documentation and the npm-link cheatsheet for more information.
MIT