GithubHelp home page GithubHelp logo

mfrank2016 / zerocode Goto Github PK

View Code? Open in Web Editor NEW

This project forked from authorjapps/zerocode

0.0 1.0 0.0 3.97 MB

A community-developed, free, open source, declarative API automation and load testing framework built using Java JUnit core runners for Http REST, SOAP, Security, Database, Kafka and much more. It enables to create and maintain test-cases with absolute ease.

Home Page: https://authorjapps.github.io/zerocode/

License: Apache License 2.0

Java 99.97% Dockerfile 0.03%

zerocode's Introduction

Zerocode Zerocode

Automated API testing was never so easy before

API Performance Testing Twitter Follow

Latest release: 1.3.x ๐Ÿน

Continuous Integration: Build Status
Issue Discussions: Slack
Mailing List: Mailing List
License: Apache 2.0
Gitter IM: Gitter

Zerocode makes it easy to create and maintain automated tests with absolute minimum overhead for REST,SOAP, Kafka, DB services and more. It has got best of best ideas and practices from the community to keep it super simple and the adoption is rapidly growing among the developer/tester community.

Quick Links

For a quick introduction to Zerocode and its features, visit the

Introduction

Zerocode is a new light-weight, simple and extensible open-source framework for writing test intentions in simple JSON or YAML format that facilitates both declarative configuration and automation.

Put simply, Zerocode alleviates pain and brings simplicity to the moddern api-automation. The framework manages the response validations, target API invocations,load/stress testing and security testing in a unified way using simple YAML/JSON/Fluent steps aka DSL.

For example, if your REST API URL https://localhost:8080/api/v1/customers/123 with GET method and "Content-Type": "application/json" returns the following payload and a http status code 200(OK) ,

Response:
{
    "id": 123,
    "type": "Premium High Value",
    "addresses": [
        {
            "type":"home",
            "line1":"10 Random St"
        }
    ]
}

then, we can easily validate the above API using Zerocode like below.

  • Using YAML described as below,

The beauty here is, we can use the payload/headers structure as it is without any manipulation.

---
url: api/v1/customers/123
method: GET
request:
  headers:
    Content-Type: application/json
retry:
  max: 3
  delay: 1000
verify:
  status: 200
  headers:
    Content-Type:
    - application/json; charset=utf-8
  body:
    id: 123
    type: Premium High Value
    addresses:
    - type: home
      line1: 10 Random St

or

  • Using JSON DSL described as below,
{
  "url": "api/v1/customers/123",
  "method": "GET",
  "request": {
    "headers": {
      "Content-Type": "application/json"
    }
  },
  "retry": {
    "max": 3,
    "delay": 1000
  },
  "verify": {
    "status": 200,
    "headers": {
      "Content-Type" : [ "application/json; charset=utf-8" ]
    },
    "body": {
      "id": 123,
      "type": "Premium High Value",
      "addresses": [
        {
          "type": "home",
          "line1": "10 Random St"
        }
      ]
    }
  }
}

and run it simply by pointing to the above JSON/YAML file from a JUnit @Test method.

   @Test
   @Scenario("test_customer_get_api.yml")
   public void getCustomer_happyCase(){
        // No code goes here. This remains empty.
   }

Looks simple n easy? Why not give a try? Visit the quick-start guide or user's guide for more insight.

Zerocode is used by many companies such as Vocalink, HSBC, HomeOffice(Gov) and many others to achieve accurate production drop of their micro-services.

Happy testing! ๐Ÿผ

zerocode's People

Contributors

aghorpade avatar arunvelusamyd avatar authorjapps avatar bartrobeyns avatar bethecodewithyou avatar cooljavadev avatar dinesh76in avatar jaoseguera avatar jbonn360 avatar jneate avatar macrocks avatar nirmalchandra avatar officiallysameer avatar santhoshtpixler avatar saurabhvalsangkar avatar siddhagalaxy avatar sinsuren avatar vkjha2000 avatar

Watchers

 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.