All Projects → IgorSasovets → Protractor Firefox Support

IgorSasovets / Protractor Firefox Support

Licence: mit
Custom implementation of Actions class functions for e2e testing with Protractor in Firefox

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Protractor Firefox Support

Browser
Useragent analysis tool.浏览器分析判断工具 - 用户代理、操作系统信息
Stars: ✭ 789 (+3845%)
Mutual labels:  firefox
Context Search
A Firefox WebExtension that displays a context menu, that searches for the selected text.
Stars: ✭ 26 (+30%)
Mutual labels:  firefox
Tabmarks
Web Extension for handling groups of tabs persisted as bookmarks
Stars: ✭ 13 (-35%)
Mutual labels:  firefox
Toggl Button
Toggl Button extension for Chrome and Firefox
Stars: ✭ 891 (+4355%)
Mutual labels:  firefox
Gulp Angular Protractor
Gulp plugin to run protractor tests
Stars: ✭ 25 (+25%)
Mutual labels:  protractor
Protractor Pretty Html Reporter
A jasmine reporter that produces an easy to use html report to analyze protractor test results.
Stars: ✭ 9 (-55%)
Mutual labels:  protractor
Runningcheese Firefox
A Graceful and Powerful Customized Firefox
Stars: ✭ 755 (+3675%)
Mutual labels:  firefox
Pulse
We're building the next generation of Firefox, and we're focusing on real-world speed and performance. Pulse lets you give our engineers feedback about your experience on websites that work well in Firefox and on websites that don't.
Stars: ✭ 15 (-25%)
Mutual labels:  firefox
Instagramfirstcommenter
This bot will post a predefined comment as fast as possible to a new post on the target profile. I used this to successfully win tickets for a big music festival.
Stars: ✭ 26 (+30%)
Mutual labels:  protractor
Simple Sidebar
A sample bootstrapped extension to add a Web panel sidebar.
Stars: ✭ 10 (-50%)
Mutual labels:  firefox
Scrollupfolder
A firefox addon wich goes up a folder of a website.
Stars: ✭ 18 (-10%)
Mutual labels:  firefox
Google Music Hotkeys
Browser extension that adds keyboard control to Google / YouTube Music
Stars: ✭ 25 (+25%)
Mutual labels:  firefox
Cucumber Protractor Harness
Simple starter project for incorporating cucumber (2.3.1) with protractor
Stars: ✭ 9 (-55%)
Mutual labels:  protractor
Firefox Gnome Theme
A GNOME👣 theme for Firefox🔥
Stars: ✭ 788 (+3840%)
Mutual labels:  firefox
Qogir Theme
Qogir is a flat Design theme for GTK
Stars: ✭ 874 (+4270%)
Mutual labels:  firefox
Foxr
🦊 Node.js API to control Firefox
Stars: ✭ 783 (+3815%)
Mutual labels:  firefox
Ember Inspector
Adds an Ember tab to the browser's Developer Tools that allows you to inspect Ember objects in your application.
Stars: ✭ 936 (+4580%)
Mutual labels:  firefox
Singlefilez
Web Extension for Firefox/Chrome/MS Edge and CLI tool to save a faithful copy of an entire web page in a self-extracting HTML/ZIP polyglot file
Stars: ✭ 882 (+4310%)
Mutual labels:  firefox
Ext Saladict
🥗 All-in-one professional pop-up dictionary and page translator which supports multiple search modes, page translations, new word notebook and PDF selection searching.
Stars: ✭ 8,418 (+41990%)
Mutual labels:  firefox
Gooreplacer
⚡️⚡️A browser extension to modify HTTP requests :-)
Stars: ✭ 850 (+4150%)
Mutual labels:  firefox

protractor-firefox-support

This is custom implementation of Actions class functions for e2e testing using Protractor framework in Firefox browser. If you use it, ⭐️ it.

Installation

You can simply install it into your project using this command:

npm install protractor-firefox-support --save

Examples of usage

Here are examples of custom functions usage. Functions presented as separated modules which can be imported in test files:

dragAndDrop (complete example here)

const support = require('protractor-firefox-support');

module.exports.performDnD = ({dragElmSelector = '.btn.btn-primary', dragElmIndex,
    draggable = false} = {}) => {
    const dropPoint = {x: 100, y: 100};
    const options = {makeDraggable: draggable, dropLocation: dropPoint};

    /**
     *  You can define dragElement index if there are more than
     *  one element with specified selector.
     */

    (dragElmIndex) ? options.dragElemIndex = dragElmIndex : null;

    /**
     *  Also you can pass selector instead of null, if you want to specify
     *  drop element.
     */
    return browser.executeScript(support.dragAndDrop, dragElmSelector, null, options);
}

openContextMenu(rightMouseClick, complete example here)

const support = require('protractor-firefox-support');

module.exports.openElementContextMenu = ({selector, elemIndex} = {}) => {
    const options = {location: {x: 100, y: 100}};

    /**
     *  If there are more elements which match specified selector, add elemIndex option.
     *  Property 'location' defines screen coordinates where context menu will be opened.
     */

    (elemIndex) ? options.elemIndex = elemIndex : null;
    return browser.executeScript(support.rightMouseBtnClick, selector, options);
}

mouseUp (complete example here)

const support = require('protractor-firefox-support');

module.exports.mouseUp = (pointCoordinates = {x: 100, y: 100}) => {
    return browser.executeScript(support.mouseUp, pointCoordinates);
}

mouseMove (complete example here)

const support = require('protractor-firefox-support');

module.exports.mouseMove = (pointCoordinates = {x: 100, y: 100}) => {
    return browser.executeScript(support.mouseMove, pointCoordinates);
}

mouseDown (complete example here)

const support = require('protractor-firefox-support');

module.exports.mouseDown = ({selector, index} = {}) => {
    /**
     *  If there are more elements which match specified selector, add elementIndex option.
     */
    return browser.executeScript(support.mouseDown, {elementSelector: selector,
      elementIndex: index});
}

mouseClick (complete example here)

const support = require('protractor-firefox-support');

module.exports.mouseClick = ({elemSelector, point, tgtIndex} = {}) => {
   const options = {};
   (elemSelector) ? options.selector = elemSelector : null;
   (point) ? options.point = point : null;
   (tgtIndex) ? options.elementIndex = tgtIndex : null;
   return browser.executeScript(support.mouseClick, options);
}

changeInputText(beta, complete example here)

const support = require('protractor-firefox-support');

module.exports.changeInputText = (selector, text, {elemIndex} = {}) => {
    /**
    *  If there are more elements which match specified selector, add elemIndex option.
    */
    const options = {};
    (elemIndex) ? options.elemIndex = elemIndex : null;
    return browser.executeScript(support.changeInputText, selector, text, options);
} 

dispatchEvent(complete example here)

const support = require('protractor-firefox-support');

module.exports.dispatchEvent = ({selector, tgtIndex, eventType, isMouseEvent} = {}) => {
    /**
    *  If there are more elements which match specified selector, add elementIndex option.
    */
    const options = {selector: selector, eventType: eventType, isMouseEvent: isMouseEvent};
    (tgtIndex) ? options.elementIndex = tgtIndex : null;
    return browser.executeScript(support.dispatchEvent, options);
} 

Run tests

First of all you need to install necessary packages using next command:

npm run install-modules-tests

Then update webdriver-manager packages, start it and run tests:

npm run webdriver-update-windows
npm run webdriver-start-windows
npm run test-windows

for Windows or

npm run webdriver-update-linux
npm run webdriver-start-linux
npm run test-linux

for Linux/MacOS.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].