Git Product home page Git Product logo

perficient's Introduction

CHALLENGE

Using the following API Definition:

https://petstore.swagger.io/#/

Create a collection with two requests:

  1. Create a Pet, create tests to verify it was created successfully.
  2. Get a Pet, create tests to verify you're getting the expected pet.
  3. Place an order for the created Pet.
  4. Get the order created in step 3, and verify it has the expected data.
  5. Automate it using newman.

Hint: You will probably need to use environments to store some data that needs to be shared between requests.

Upload the solution to a repo, put in the README instructions about how to execute your code, share the solution as a response to this message :)

OS

This program was fully developed on Windows 11.

THINGS YOU MIGHT NEED BEFORE STARTING

  • node js.

    Alt text

  • postman.

    Alt text

  • newman.

    Alt text

  • newman html reporter.

    Alt text

  • jenkins.

    Alt text

HOW TO RUN THIS POGRAM

  1. Download The Challenge 1 Folder into a location inside your computer.
  2. Open Jenkins and Configure a new Job.

Alt text 3. Go into your newly created job and add the following lines under build:

```
    cd "Path to where your downloaded challenge 1 folder "
    "C:\Users\youruser\AppData\Roaming\npm\newman" run Swagger_Petstore.postman_collection.json -e QA_Testing  postman_environment.json -g workspace.postman_globals.json
    "C:\Users\youruser\AppData\Roaming\npm\newman" run Swagger_Petstore.postman_collection.json -e QA_Testing.postman_environment.json -g workspace.postman_globals.json -r htmlextra
```

Alt text

  1. In order to see a proper rendering of postman report lines go to you jenkins folder and open with a text editor the jenkins.xml file, at line 39 before the word -jar add -Dfile.encoding=UTF8.

Alt text

  1. Finally run your build. Alt text

  2. Go to the path of your local folder and inside the newman sub-folder with the help of a browser open the respective report.

Alt text

perficient's People

Contributors

sebastiangomezvidal avatar

Watchers

 avatar

perficient's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.