Skip to content

r3sm/CaseStudy-Target

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

[TOC]

Case Study

The goal for this exercise is to create an end-to-end Proof-of-Concept for a products API, which will aggregate product data from multiple sources and return it as JSON to the caller

Requirement

Build an application that performs the following actions:

· Responds to an HTTP GET request at /products/{id} and delivers product data as JSON (where {id} will be a number.

· Accepts an HTTP PUT request at the same path (/products/{id}), containing a JSON request body similar to the GET response, and updates the product’s price in the data store.

Tools used

ABAP stack is used to complete this task. ABAP trail instance is available for developers.

Bonsai is used as NoSQL DB.

Postman is used for testing the API.

Installation

Instances of below two Services are required. Please set up and have the service key available for later use.

Free ABAP Trail account setup

Setup Authorization and Trust Management Service Instance

Go to highlighted Service and create a service Instance and choose plant - apiaccess. Create a Service Key.

Clone the Source Repo

This repository can be cloned using abapGit to your package.

After the pull request, if you see any errors please follow the below sequence in activating the pulled repo objects.

If you are already on the same instance and cannot be cloned, please proceed to next step.

Postman Setup

Since We need to test both GET and PUT calls , installing latest version of postman will be helpful before beginning the setup.

After setting up postman, import below files.

postman/Assessment Enironment template.postman_environment.json

postman/Target Case Study.postman_collection.json

Setup Environment File

After importing the Environment template, please set the variable as per below.

Make sure to choose this Environment before proceeding to next step.

AUTH Token Generation

After above setup is complete, final step is to generate an AUTH token to be able to start testing.

Follow highlighted steps from Screen shots below to generate an access token and set it up for use.

Testing

​ Test scenarios are already part of the collection shared.

​ Please run the folder 'Unit Test'

TEST RESULTS:

About

Target Case Study

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published