open-index/open-npm huggingface dataset:
npm package: @rpii/wdio-commands
Description: Add task based commands to simplify the webdriverio api,compatible with v7
Author: rpii
Latest version: 8.0.2

# @rpii/wdio-commands

##Newest Features:
    Updated for module compatibility with webdriver 8

    Update to async mode in webdriverio 
        -- may get some tsc warnings
    Update typescript types for webdriverio 7.25
    Remove moment.js

## Usage
Typescript package which provides aggregated webdriver.io commands to perform complex actions
This package adds the following commands to the WebDriverIO Element:

```
            setCheckBox: (state: boolean) => Element;
            isDisplayedWithin: (timeout: undefined | number) => boolean;
            waitForExistAndClick: (timeout: undefined | number) => Element;
            waitForDisplayedAndClick: (timeout: undefined | number) => Element;
            waitForExistAndSetValue: (value: string, timeout: undefined | number) => Element;
            waitForExistAndSelectByValue: (value: string, timeout: undefined | number) => Element;
            waitForDisplayedAndSetValue: (timeout: undefined | number) => Element;
            waitForNotExist: (timeout: undefined | number) => Element;
            waitForNotDisplayed: (timeout: undefined | number) => Element;
            waitUntilTextBecomes(text:string|RegExp , timeout?: number| undefined): boolean
```
to use add to wdio.conf.js:

```
import commands from "@rpii/wdio-commands" ;
```
add to the before hook:
```
commands.addCommands(browser) ;
```
###Sample

    in a page object:
```

    $("//button[@id='submit-button']").waitForVisibleAndClick(2000) ;
```

The default Wait Time is 10 seconds if the timeout is omitted
npm package: @rpii/wdio-html-reporter-pdf
Description: WebdriverIO report add on. Converts HTML formatted report to pdf
Author: Rich Peters
Latest version: 8.0.7

# wdio-html-reporter-pdf
Generate a pdf from an html-report.  
Requires version 8.1.0 or later of wdio-html-nice-reporter to generate the html report
#### Lock the puppeteer version to prevent issues

#### Fixes to render a very large html file

#### Converted to ES Module
    bug fix for expanding sections in new puppeteer


### Updated for module compatibility with webdriver 8
#### Newest Features:

    Upgrade: Set timeout to 0 to prevent timeouts
    Upgrade: update puppeteer version.  
    Upgrade: rewritten in typescript, update puppeteer.  


## Installation

The easiest way is to keep the `@rpii/wdio-html-reporter-pdf` as a devDependency in your package.json:

```javascript
{
  "devDependencies": {
    "@rpii/wdio-html-reporter-pdf": "~7.0.0"
  }
}
```
## Updates

Updated version of puppeteer to get rid of issues.


## Configuration
Add a file called make-pdf.ts in the root of the project.

There are difficulties in puppeteer if you try to integrate the code into wdio.conf.js.

The following code shows a simple way to add as a post build action.  you can invoke it from a pipeline if you are using jenkins.


```javascript / babel

// babel version
const path = require("path") ;
const fs = require("fs-extra") ;

let printPdf = require('@rpii/wdio-html-reporter-pdf').default ;

(async () => {
    let args = process.argv.slice(2) ;
    let reportName = args[0] ? args[0] : "master-report";

    try {

        // need full paths
        let htmlReportFile = path.resolve(__dirname, 'reports/html-reports/' + reportName + '.html');
        let pdfFile = path.resolve(__dirname, 'reports/' + reportName + '.pdf');
        //for linux you will need these options
        let options = ['--no-sandbox', '--disable-gpu', '--disable-extensions'];
        await printPdf(htmlReportFile, pdfFile, options);
    } catch (ex)  {
        console.error(ex);
    }
})();
    
``` 

Add a line to your package.json under scripts
```javascript
    "pdf": "node make-pdf.ts"
``` 
To use an already installed chrome:  Add a line to your package.json under scripts

```javascript
    "pdf-chrome-linux": "node make-pdf.ts /usr/bin/google-chrome"
``` 

## Usage
Run after completing a build.

If you need to specify a path to chrome, that is the fourth parameter.
npm package: @rpii/wdio-report-events
Description: Abstracts the event driven messaging to pass screenshots, videos  and log data to the report module
Author: Rich Peters
Latest version: 8.0.2

# @rpii/wdio-report-events

### Updated for module compatibility with webdriver 8

Abstracts the event driver messaging to pass screenshots and log data to webdriverio reports

Used internally by various packages that need to fire events, and listen for them.  

Easy to update if webdriver.io changes the report scheme again.