Git Product home page Git Product logo

abap-odata-smoke-test's Introduction

Important Notice

This public repository is read-only and no longer maintained.

ABAP ODATA Smoke-Test tool

Description

Any projects that are using ODATA services from an ABAP environment, as for example within SAP Fiori Apps, and are looking for a basic testing tool, can use this smoke-test technique to verify basic ODATA functionality.

This ABAP Report performs simple smoke tests for activated ODATA services all at once, providing basic automated testing for your ODATA endpoints. These smoke tests mainly cover the retrieval of ODATA service metadata and optionally can perform an arbitary entityset request. The resulting HTTP response codes are collected (e.g. OK = HTTP 200) and displayed in a list view.

Report Flow:

  • Evaluates all activated ODATA Services (as in transaction /IWFND/MAINT_SERVICE)
  • Performs a $metadata call
  • (Optional) Performs a service document call
  • (Optional) Performs an arbitary entityset call
  • Collects HTTP Status Codes / Responses and outputs it to the Application Log (transaction SLG1)

Limitations

There is no validation of request content, data correctness or completeness. Also notice, that for arbitary entityset calls, not necessarily every call might succeed, as some entities require mandatory parameters! Further testing therefore could be done using third party tools, that can verify and correlate each ODATA service request.

Requirements

The provided coding works in any environment, that meets the following technical prerequisites:

  • SAP Netweaver ABAP >= 7.51 environment e.g. tested on SAP S/4HANA 1709/1809
  • Software component SAP_GWFND (Gateway) installed
  • Requires working Gateway Client functionality (uses HTTP) - check also transaction "/IWFND/GW_CLIENT"
  • User with SAP_ALL or similar authorizations to execute ODATA services and perform entityset calls

Download & Installation

It is actually not necessary to download any files, you can easily copy and paste the required code fragments directly, as mentioned below. If you still like to have a local copy, you can follow this guide.

  • Run SAPGUI, execute transaction "SE38"
  • create new executable report e.g. Z_ODATA_SMOKE_TEST
  • Copy & Paste Source Code
  • Save & Activate

Execution

After installation/deployment, run report via "SE38".

Flag <test_entity = abap_false.> determines, whether entityset calls are performed (default = off).

ATTENTION: Depending on the amount of active services, especially the initial execution can take minutes up to couple of hours!

Output

Once finished, results will be shown automatically! Moreover, they can also be observed via transaction "SLG1", Object "/IWFND/", Subobject "RUNTIME", as seen below. The result list can easily be sorted and help during further troubleshooting.

demo smoke test

Support

This project is provided "as-is", with no support or changes planned.

License

Copyright (c) 2018 SAP SE or an SAP affiliate company. All rights reserved.

The content of this repository is licensed under the SAP SAMPLE CODE LICENSE AGREEMENT as noted in the LICENSE file.

abap-odata-smoke-test's People

Contributors

btbernard avatar frumania avatar jonathanbaker7 avatar larshp avatar

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.