Skip to content

aisyahns/automation-api-implementation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Introduction

This is a sample of po-gen implementation in several public API, which are:

  1. Demo QA
  2. Pet Store

Installation

  1. Install NodeJS and NPM

    Check if node and npm are successfully installed:

    node -v
    npm -v
  2. Clone repo

  3. Create .env.dev file with key-value inside:

    key example value description
    MAIN bookstore_url
    petstore_url
    petstore API is used to give sample for upload file case and the rest is given by bookstore API
    USER_ID 99741930-****** user id obtained from registration response in bookstore API
    USER_NAME automation**** user name valid static for automation purpose
    PASSWORD Password123! password valid static for automation purpose

    P.S: for MAIN value, you can change the value when you need to run one of the case (which are upload file case or the rest)

    P.S: for user id, user name, and password value, you can get them from creating new account in bookstore API.

  4. Run regression runner with:

    npm run test:dev
  5. Run runner with mochawesome report:

    npm run report:dev
  6. Run runner for specific runner, which is file.js:

    npm run test runner/file.js

Directory Example

Case: Upload file / attachment

You can see from:

Case: Request get only

You can see from:

Case: Request with body and DDT mechanism

You can see from:

Case: Request with another argument

You can see from:

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published