{ "info": { "author": "Isaac Rodriguez", "author_email": "oss.abantos@outlook.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 1 - Planning", "Environment :: Console", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Programming Language :: Python", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7", "Topic :: Internet :: WWW/HTTP", "Topic :: Software Development :: Testing :: Acceptance", "Topic :: Software Development :: Testing :: BDD" ], "description": "\nBehave Restful\n==============\n\n\n.. image:: https://travis-ci.org/behave-restful/behave-restful.svg?branch=master\n :target: https://travis-ci.org/behave-restful/behave-restful\n :alt: Build Status\n\n\nBehave Restful is a Behavior Driven Development (BDD) framework based on \n`behave `_\\ , that implements a language suitable \nto test and validate REST APIs and Services. It leverages the power of the \n`gherkin `_ language to write \nbusiness readable tests that validate the behavior of REST APIs.\n\nAlthough, Behave Restful is implemented in `python `_ and \nuses `behave `_ as underlying framework, it can \ntest services implemented in any language as easy as:\n\n.. code-block:: gherkin\n\n\n Feature: API to add a new book to our collection\n As a user, I want to add a new book to my \"to-read\" collection.\n\n Scenario: Add a new book to collection.\n Given a request url http://my.reads/api/books\n And a request json payload\n \"\"\"\n {\n \"category\": \"reference\",\n \"author\": \"Nigel Rees\",\n \"title\": \"Sayings of the Century\",\n \"price\": 8.95,\n \"status\": \"to-read\"\n }\n \"\"\"\n When the request sends POST\n Then the response status is CREATED\n And the response json matches\n \"\"\"\n {\n \"title\": \"BookObject\",\n \"type\": \"object\"\n \"properties\": {\n \"id\": {\"type\": \"number\"},\n \"category\": {\"type\": \"string\"},\n \"author\": {\"type\": \"string\"},\n \"title\": {\"type\": \"string\"},\n \"price\": {\"type\": \"number\"},\n \"status\": {\"type\": \"string\", \"enum\": [\"to-read\", \"reading\", \"read\"]}\n },\n \"required\": [\"id\", \"category\", \"title\"]\n }\n \"\"\"\n And the response json at $.id is equal to 100\n And the response json at $.category is equal to \"reference\"\n And the response json at $.title is equal to \"Sayings of the Century\"\n\nAs you can see in the example, we send a POST request to the specified url with\na JSON payload, and we can validate the result very easy. First, we verify that\nthe status of the response is CREATED (it succeeds). Then we validate the\nresponse JSON body using the expected `JSON Schema `_. \nFinally, we validate specific values in the response using \n`JSONPath `_\n\nInstallation\n------------\n\nUse pip to install behave-restful in your project\n\n.. code-block::\n\n pip install behave-restful\n\nSetup\n-----\n\nTo add support for ``behave-restful`` steps in your ``.feature`` files, you need to include behave-restful's environment and step definitions.\n\nYou can do this simply by adding two boilerplate files to your project:\n\nIn the root of your ``features`` directory, add this ``environment.py`` file:\n\n.. code-block:: python\n\n # {your_project}/features/en/__init__.py\n\n import os\n\n import behave_restful.app as br_app\n\n\n def before_all(context):\n this_directory = os.path.abspath(os.path.dirname(__file__))\n br_app.BehaveRestfulApp().initialize_context(context, this_directory)\n context.hooks.invoke(br_app.BEFORE_ALL, context)\n\n\n def after_all(context):\n context.hooks.invoke(br_app.AFTER_ALL, context)\n\n\n def before_feature(context, feature):\n context.hooks.invoke(br_app.BEFORE_FEATURE, context, feature)\n\n\n def after_feature(context, feature):\n context.hooks.invoke(br_app.AFTER_FEATURE, context, feature)\n\n\n def before_scenario(context, scenario):\n context.hooks.invoke(br_app.BEFORE_SCENARIO, context, scenario)\n\n\n def after_scenario(context, scenario):\n context.hooks.invoke(br_app.AFTER_SCENARIO, context, scenario)\n\n\n def before_step(context, step):\n context.hooks.invoke(br_app.BEFORE_STEP, context, step)\n\n\n def after_step(context, step):\n context.hooks.invoke(br_app.AFTER_STEP, context, step)\n\n\n def before_tag(context, tag):\n context.hooks.invoke(br_app.BEFORE_TAG, context, tag)\n\n\n def after_tag(context, tag):\n context.hooks.invoke(br_app.AFTER_TAG, context, tag)\n\nAnd under ``features/steps`` add this ``__init__.py`` file:\n\n.. code-block:: python\n\n # {your_project}/features/steps/__init__.py\n from behave_restful.lang import *\n\n\n", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/behave-restful/behave-restful", "keywords": "rest bdd behave gherkin test automation testing", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "behave-restful", "package_url": "https://pypi.org/project/behave-restful/", "platform": "", "project_url": "https://pypi.org/project/behave-restful/", "project_urls": { "Homepage": "https://github.com/behave-restful/behave-restful" }, "release_url": "https://pypi.org/project/behave-restful/0.1.12/", "requires_dist": [ "assertpy (>=0.12)", "behave (>=1.2.5)", "jsonpath-rw (>=1.4.0)", "jsonschema (>=2.6.0)", "requests (>=2.18.4)" ], "requires_python": "", "summary": "Implements Gherking language for REST services.", "version": "0.1.12" }, "last_serial": 5625177, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "02b947e4fcb1d1b04e57403135d4f5e3", "sha256": "489b3d4851d8760d77aa51753ab702dd693b4072d358b10fa92d0a5fc8cc65b3" }, "downloads": -1, "filename": "behave-restful-0.1.0.tar.gz", "has_sig": false, "md5_digest": "02b947e4fcb1d1b04e57403135d4f5e3", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8510, "upload_time": "2018-02-10T17:12:53", "url": "https://files.pythonhosted.org/packages/60/89/cfd26d6f4d2c6a3f3736b35902e07805d19d9f86594a51be6f680aaf7049/behave-restful-0.1.0.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "e467652e45b97a864ca88917521198db", "sha256": "b12b8e7517f5b2cf503f200b004ec0ad49604e9ca914b7f4f4ed25a9d2c9cdbd" }, "downloads": -1, "filename": "behave-restful-0.1.1.tar.gz", "has_sig": false, "md5_digest": "e467652e45b97a864ca88917521198db", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8512, "upload_time": "2018-02-10T18:12:04", "url": "https://files.pythonhosted.org/packages/5c/5b/b38580a5a144061ea0418d05d930fc110852725a248222ca4b8791781d72/behave-restful-0.1.1.tar.gz" } ], "0.1.10": [ { "comment_text": "", "digests": { "md5": "6d4341212253bb5aff622e40353a642d", "sha256": "167f98f890b6e30d8cdc93ac866b50b4c775a12de2b938005670d233c2692c73" }, "downloads": -1, "filename": "behave_restful-0.1.10-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "6d4341212253bb5aff622e40353a642d", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 15761, "upload_time": "2019-03-22T23:19:47", "url": "https://files.pythonhosted.org/packages/04/1f/227da30100a15fdbb8365537c683099efdd3468097ae2f1fe1c4946b4355/behave_restful-0.1.10-py2.py3-none-any.whl" } ], "0.1.11": [ { "comment_text": "", "digests": { "md5": "2232b0f9e095fbca72c754c6a30f3966", "sha256": "9a5fafb711447800984e81d58a3043cae725f5b2c15605a2d31399e71831d369" }, "downloads": -1, "filename": "behave_restful-0.1.11-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "2232b0f9e095fbca72c754c6a30f3966", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 18287, "upload_time": "2019-06-27T16:29:55", "url": "https://files.pythonhosted.org/packages/a9/9a/a2bd29f1e9931ad3080e8213030b7059daf473fd2decc9cb16a08203377f/behave_restful-0.1.11-py2.py3-none-any.whl" } ], "0.1.12": [ { "comment_text": "", "digests": { "md5": "c2c75381ad3497aaf37f49827add9fc0", "sha256": "1bb815287b98ac1baf0b64b62210d915d8db8c57049d464d957075ff4a517ecb" }, "downloads": -1, "filename": "behave_restful-0.1.12-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "c2c75381ad3497aaf37f49827add9fc0", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 18300, "upload_time": "2019-08-02T16:41:28", "url": "https://files.pythonhosted.org/packages/54/74/c8b6df717163d92bc8443b6cf81c0b53321d4bb0eef822c74bb7c3375876/behave_restful-0.1.12-py2.py3-none-any.whl" } ], "0.1.2": [ { "comment_text": "", "digests": { "md5": "c4ea15476c950a5b2491527f42f57fee", "sha256": "7b8024e973046521a40e1a529cc302cfedd401176ef874499c80e4d012be956c" }, "downloads": -1, "filename": "behave-restful-0.1.2.tar.gz", "has_sig": false, "md5_digest": "c4ea15476c950a5b2491527f42f57fee", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8502, "upload_time": "2018-02-10T18:55:59", "url": "https://files.pythonhosted.org/packages/21/7f/6fa078016115e67ffe924fb3bb9b54a40297ab5d470ff1d163a6eae79057/behave-restful-0.1.2.tar.gz" } ], "0.1.3": [ { "comment_text": "", "digests": { "md5": "15ce1ffb5764b288327ce125aeab2c69", "sha256": "d61a35022c427b3ad413c9f2d8404d91cfa776f9031ced96428b0ca38ac2abbb" }, "downloads": -1, "filename": "behave-restful-0.1.3.tar.gz", "has_sig": false, "md5_digest": "15ce1ffb5764b288327ce125aeab2c69", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8457, "upload_time": "2018-02-10T19:05:23", "url": "https://files.pythonhosted.org/packages/e2/63/dcd2cf0a4625dbeaa823f12d525e4c623743b124bc7f3c3c75df310c6118/behave-restful-0.1.3.tar.gz" } ], "0.1.4": [ { "comment_text": "", "digests": { "md5": "eb5cb5b2f86b4707dbf607a2c804454a", "sha256": "2756ed25d2b3ce95feec45e4c72c9b888c187d4a3360f1b097b32ace425a66a3" }, "downloads": -1, "filename": "behave-restful-0.1.4.tar.gz", "has_sig": false, "md5_digest": "eb5cb5b2f86b4707dbf607a2c804454a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8594, "upload_time": "2018-02-12T23:39:38", "url": "https://files.pythonhosted.org/packages/4f/28/4192aa499e5eed688d8a2f77453f81ffdccef60baae25a295809390829d5/behave-restful-0.1.4.tar.gz" } ], "0.1.5": [ { "comment_text": "", "digests": { "md5": "cb4a8c5045ed84786ec52d86b1eaf20a", "sha256": "a054688d53b293262b231aaa95c37689af581e75a0ac56b4a80f832c66375cf8" }, "downloads": -1, "filename": "behave-restful-0.1.5.tar.gz", "has_sig": false, "md5_digest": "cb4a8c5045ed84786ec52d86b1eaf20a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8676, "upload_time": "2018-02-23T18:59:41", "url": "https://files.pythonhosted.org/packages/f9/a6/8ece093a01af4f5342e7cd52d642ba9c2d681e4f5540dd7fb980585e8ef7/behave-restful-0.1.5.tar.gz" } ], "0.1.6": [ { "comment_text": "", "digests": { "md5": "e9dfad32f19a97eb726e76821a6f480c", "sha256": "030deba2f1a61c99afff3080a0bfa3dbde45c9d6ae0459419d44da0796da127f" }, "downloads": -1, "filename": "behave_restful-0.1.6-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "e9dfad32f19a97eb726e76821a6f480c", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 11916, "upload_time": "2018-05-15T18:41:51", "url": "https://files.pythonhosted.org/packages/ba/a9/e7e2ff724caac9bcab14eaaae7ed99a6cd257be099f79ecf0e6c6270372e/behave_restful-0.1.6-py2.py3-none-any.whl" } ], "0.1.7": [ { "comment_text": "", "digests": { "md5": "800bf09dae095510c65f0fb7bdfe37b7", "sha256": "8495f73b77af30a1b7364974a82ac31ac65f10e7876fb622fc7fe62ca23b235d" }, "downloads": -1, "filename": "behave_restful-0.1.7-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "800bf09dae095510c65f0fb7bdfe37b7", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 14024, "upload_time": "2018-10-21T02:13:27", "url": "https://files.pythonhosted.org/packages/e5/2e/dec57f5b15471aeaaed7ad7b4d5b97bd139047190a253599635c99419dc8/behave_restful-0.1.7-py2.py3-none-any.whl" } ], "0.1.8": [ { "comment_text": "", "digests": { "md5": "27b3878a414878b577a946b3e8581666", "sha256": "dad198f90932ab52e08894bf6979422d8cf68c12f03ee380959cda21d2f3b22a" }, "downloads": -1, "filename": "behave_restful-0.1.8-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "27b3878a414878b577a946b3e8581666", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 14310, "upload_time": "2018-10-21T20:07:30", "url": "https://files.pythonhosted.org/packages/27/2b/3b3a136722546d8949b5a807859bc4318f29f82d7526b3207e9476f99769/behave_restful-0.1.8-py2.py3-none-any.whl" } ], "0.1.9": [ { "comment_text": "", "digests": { "md5": "45e9770fe9d6954fdb554829b2e6b7cc", "sha256": "f21d1e8b31b62172b303d0ecab91095791a3c76fee5ae69a78c53a459215f2c1" }, "downloads": -1, "filename": "behave_restful-0.1.9-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "45e9770fe9d6954fdb554829b2e6b7cc", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 14210, "upload_time": "2018-12-20T15:07:19", "url": "https://files.pythonhosted.org/packages/ea/37/c2ec6fa871dde0d315cb53d2c1ea6f54a8ad27aebb51cb750db55ee807a8/behave_restful-0.1.9-py2.py3-none-any.whl" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "c2c75381ad3497aaf37f49827add9fc0", "sha256": "1bb815287b98ac1baf0b64b62210d915d8db8c57049d464d957075ff4a517ecb" }, "downloads": -1, "filename": "behave_restful-0.1.12-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "c2c75381ad3497aaf37f49827add9fc0", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 18300, "upload_time": "2019-08-02T16:41:28", "url": "https://files.pythonhosted.org/packages/54/74/c8b6df717163d92bc8443b6cf81c0b53321d4bb0eef822c74bb7c3375876/behave_restful-0.1.12-py2.py3-none-any.whl" } ] }