{ "info": { "author": "Jussi Vatjus-Anttila", "author_email": "jussiva@gmail.com", "bugtrack_url": null, "classifiers": [ "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7" ], "description": "# Python Client library for OpenTMI\n\n[![CircleCI](https://circleci.com/gh/OpenTMI/opentmi-pyclient/tree/master.svg?style=svg)](https://circleci.com/gh/OpenTMI/opentmi-pyclient/tree/master)\n[![Coverage Status](https://coveralls.io/repos/github/OpenTMI/opentmi-pyclient/badge.svg)](https://coveralls.io/github/OpenTMI/opentmi-pyclient)\n[![PyPI version](https://badge.fury.io/py/opentmi-client.svg)](https://badge.fury.io/py/opentmi-client)\n\nThis is the Python client library for [OpenTMI](https://github.com/opentmi/opentmi).\n\n## installation\n\nTo install, simply use `pip`:\n\n`$ pip install --upgrade opentmi-client`\n\nSee the [Developers Guide](development.md) if you want to develop this library.\n\n## Command Line Interface\n\nLibrary provides Command line Interface to communicate with OpenTMI -backend\n\n```\n$ opentmi --help\nusage: opentmi [-h] [-v] [-s] [--host HOST] [--user USER]\n [--password PASSWORD] [--token TOKEN]\n [--token_service TOKEN_SERVICE] [-p PORT]\n ...\n\noptional arguments:\n -h, --help show this help message and exit\n -v verbose level... repeat up to three times.\n -s, --silent Silent - only errors will be printed\n --host HOST OpenTMI host, default: localhost\n --user USER username\n --password PASSWORD password\n --token TOKEN Authentication token\n --token_service TOKEN_SERVICE\n Optional authentication service\n -p PORT, --port PORT OpenTMI port\n\nsubcommand:\n sub-command help\n version Display version information\n list List something\n store Create something\n```\n\nexample:\n```\nopentmi --host localhost --port 3000 --list --testcases 1\n```\n\n## Python API\n\n```\nfrom opentmi_client import OpenTmiClient, Result, Event\nclient = Client(\"https://127.0.0.1\")\nclient.login_with_access_token(\"my-github-access-token\")\n\n# post result\nresult = Result()\nresult.tcid = \"test-case-a\"\nresult.verdict = \"pass\"\nclient.post_result(result)\n\n# post event\nevent = Event()\nevent.msgid = \"ALLOCATED\"\nevent.priority.level = \"info\",\nevent.ref.resource = \"5697740f956cd2fd35c69062\"\nclient.post_event(event)\n```\n\nSee more examples from [here](https://github.com/OpenTMI/opentmi-pyclient/tree/master/examples).\n\nServer side Result schema can be found from [here](https://github.com/OpenTMI/opentmi/blob/master/app/models/results.js#L15).\nand Test case schema is available [here](https://github.com/OpenTMI/opentmi/blob/master/app/models/testcase.js).\n\n**notes**\n\n* `tcid` -field have to be unique for each test cases.\n* There is couple mandatory fields by default: `tcid` and `exec.verdict`. Allowed values for result verdict is: `pass`, `fail`, `inconclusive`, `blocked` and `error`. `upload_results()` -function also create test case document if it doesn't exists in database.\n\n## Authentication\n\nThere are multiple options to authenticate:\n* use `Client.login(, )`\n* use `Client.login_with_access_token(, [])`\n * service are optional and supported values depend on server support.\n By default `github` is in use.\n* Use environment variables (tries login automatically when constructor is called):\n * Using username and password: `OPENTMI_USERNAME` and `OPENTMI_PASSWORD` or\n * Using github access token: `OPENTMI_GITHUB_ACCESS_TOKEN`\n* use token in host like `http://@localhost`\n\n## LICENSE\n\n[MIT](LICENSE)\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/OpenTMI/opentmi-pyclient.git", "keywords": "opentmi ci cd api sdk", "license": "MIT", "maintainer": "Jussi Vatjus-Anttila", "maintainer_email": "jussiva@gmail.com", "name": "opentmi-client", "package_url": "https://pypi.org/project/opentmi-client/", "platform": "", "project_url": "https://pypi.org/project/opentmi-client/", "project_urls": { "Homepage": "https://github.com/OpenTMI/opentmi-pyclient.git" }, "release_url": "https://pypi.org/project/opentmi-client/0.5.0/", "requires_dist": [ "requests (>=2.13.0)", "jsonmerge", "six", "pydash", "junitparser" ], "requires_python": "", "summary": "opentmi-client", "version": "0.5.0" }, "last_serial": 4774706, "releases": { "0.3.2": [ { "comment_text": "", "digests": { "md5": "fff747f6a41069b90a239d285adf3e12", "sha256": "1199889cc9a522f5981959540889986212c13556af20e13c400cbba89a512820" }, "downloads": -1, "filename": "opentmi_client-0.3.2-py2.7.egg", "has_sig": false, "md5_digest": "fff747f6a41069b90a239d285adf3e12", "packagetype": "bdist_egg", "python_version": "2.7", "requires_python": null, "size": 28218, "upload_time": "2018-09-05T20:10:24", "url": "https://files.pythonhosted.org/packages/2b/28/c0f1393a67e09f4cd8b1df91553ce909fd425a0a5902e045ca98f06be229/opentmi_client-0.3.2-py2.7.egg" }, { "comment_text": "", "digests": { "md5": "7ca76c95d05f2e562d699f48b2a6dae3", "sha256": "de36a771dba1c4bb17e9fa1f331f4c4e3d3f113ad5448bc98ca64249a73c6fe0" }, "downloads": -1, "filename": "opentmi_client-0.3.2-py2-none-any.whl", "has_sig": false, "md5_digest": "7ca76c95d05f2e562d699f48b2a6dae3", "packagetype": "bdist_wheel", "python_version": "py2", "requires_python": null, "size": 12884, "upload_time": "2018-09-05T20:10:21", "url": "https://files.pythonhosted.org/packages/65/33/b1fe5bf0fc6a799a4643391f6c9050bfcd063a7d8ea762a7eace72ffbfaa/opentmi_client-0.3.2-py2-none-any.whl" }, { "comment_text": "", "digests": { "md5": "8b9809d91a93ccfbdb8e0f81aa28125d", "sha256": "d447763be762673e292e962da6735c1488d0f6d3c0eecfba053e4f4bacb9ecb2" }, "downloads": -1, "filename": "opentmi_client-0.3.2.tar.gz", "has_sig": false, "md5_digest": "8b9809d91a93ccfbdb8e0f81aa28125d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14363, "upload_time": "2018-09-05T20:10:25", "url": "https://files.pythonhosted.org/packages/3e/e7/8a914f8a08a26adc94d0941e84175902db6d959987d7dddfc2a30a4b61fe/opentmi_client-0.3.2.tar.gz" } ], "0.3.3": [ { "comment_text": "", "digests": { "md5": "bf0665169a4763aba02da470eeeb8071", "sha256": "7afa8d24f1045f56bd5868947c5a8e697ae897f35c5fbdfaca9d54e5ef86bd3f" }, "downloads": -1, "filename": "opentmi_client-0.3.3-py2-none-any.whl", "has_sig": false, "md5_digest": "bf0665169a4763aba02da470eeeb8071", "packagetype": "bdist_wheel", "python_version": "py2", "requires_python": null, "size": 12910, "upload_time": "2018-09-05T20:10:22", "url": "https://files.pythonhosted.org/packages/d5/83/30e18bb0cee8aa9aa68a0f00888f070fb2ead2b2ee0c2b95b286865d83da/opentmi_client-0.3.3-py2-none-any.whl" }, { "comment_text": "", "digests": { "md5": "47ce674fedc4f8da718a8038249b20f7", "sha256": "90e02dc6e34f1be19621328bcd05fdddadb8ae74fbd5ab3e0c47490c774dde5d" }, "downloads": -1, "filename": "opentmi_client-0.3.3.tar.gz", "has_sig": false, "md5_digest": "47ce674fedc4f8da718a8038249b20f7", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14421, "upload_time": "2018-09-05T20:10:27", "url": "https://files.pythonhosted.org/packages/c9/13/d7b23e8e2e40069b0ccfa9836f72fc73404b1be0bb7c27f24bb3525ae823/opentmi_client-0.3.3.tar.gz" } ], "0.4.0": [ { "comment_text": "", "digests": { "md5": "fef00cd50c85add7d9a79252a03bdc18", "sha256": "0b8d622e5e555d984caadca33041469e4b7978bef421099240e2433fcfb40d3b" }, "downloads": -1, "filename": "opentmi_client-0.4.0-py3-none-any.whl", "has_sig": false, "md5_digest": "fef00cd50c85add7d9a79252a03bdc18", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 32000, "upload_time": "2018-10-13T10:22:32", "url": "https://files.pythonhosted.org/packages/9b/d5/0cee6be6135e93d91482df6359d14c23b57dd6f6b26af9205ff155ede46b/opentmi_client-0.4.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "5f4068a01e581f79e97f68f27768b341", "sha256": "d0f4adc52994c5c217e61427fd7b2bb72714a03c056e06f384fb2c8c84da4c63" }, "downloads": -1, "filename": "opentmi_client-0.4.0.tar.gz", "has_sig": false, "md5_digest": "5f4068a01e581f79e97f68f27768b341", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26248, "upload_time": "2018-10-13T10:22:33", "url": "https://files.pythonhosted.org/packages/f2/c1/44237cb081c2b55396ef20a744f4e48d6f4b4ad56a5830ac15fbc8266956/opentmi_client-0.4.0.tar.gz" } ], "0.4.1": [ { "comment_text": "", "digests": { "md5": "df76bb8b6cfdbc196df2cba0dbcb935c", "sha256": "90896b754f7828c0a8ae3046e8a8210fde2f7b116d920bf7af9828b80c7bff1f" }, "downloads": -1, "filename": "opentmi_client-0.4.1-py3-none-any.whl", "has_sig": false, "md5_digest": "df76bb8b6cfdbc196df2cba0dbcb935c", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 32025, "upload_time": "2018-10-13T14:20:03", "url": "https://files.pythonhosted.org/packages/04/bf/7d3c5d187f9d3b9be8c2a7eeea0760326fa9f2e990c7fb2cb5bd73425b8f/opentmi_client-0.4.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "07e4b91f399a6160d4a7b9c93d4e15c8", "sha256": "9dfdef3b0e3a20ba65127c3f6dabca5a8ccd0ba7b07f8d855b344748481d38c0" }, "downloads": -1, "filename": "opentmi_client-0.4.1.tar.gz", "has_sig": false, "md5_digest": "07e4b91f399a6160d4a7b9c93d4e15c8", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26332, "upload_time": "2018-10-13T14:20:05", "url": "https://files.pythonhosted.org/packages/68/da/8ab4e962e8362236dfe533f5cf2b6bd3f7839464fee69563606784445030/opentmi_client-0.4.1.tar.gz" } ], "0.5.0": [ { "comment_text": "", "digests": { "md5": "af8ec5c9019133c0c9bcc6903c1ce44c", "sha256": "22a0bd61899a5f6925a39962f844ba14aff03005580ff18db48b9f5a5877a6d4" }, "downloads": -1, "filename": "opentmi_client-0.5.0-py3-none-any.whl", "has_sig": false, "md5_digest": "af8ec5c9019133c0c9bcc6903c1ce44c", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 34816, "upload_time": "2019-02-03T13:20:15", "url": "https://files.pythonhosted.org/packages/d3/e4/e6ef86b494ae855496a76ff5c929b7dd9e7437838f2e5e0532c41263c4df/opentmi_client-0.5.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "c781ea028a66769584d37c2470ad53fa", "sha256": "906f6d355462885f4b754e3a21e1ff3d2983e4c950cc05a35b23e69496f012a1" }, "downloads": -1, "filename": "opentmi_client-0.5.0.tar.gz", "has_sig": false, "md5_digest": "c781ea028a66769584d37c2470ad53fa", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 28329, "upload_time": "2019-02-03T13:20:17", "url": "https://files.pythonhosted.org/packages/a0/27/5092c0d533d876f5118dec19be60e0956a87d3a03e6f4d8797970ab4486a/opentmi_client-0.5.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "af8ec5c9019133c0c9bcc6903c1ce44c", "sha256": "22a0bd61899a5f6925a39962f844ba14aff03005580ff18db48b9f5a5877a6d4" }, "downloads": -1, "filename": "opentmi_client-0.5.0-py3-none-any.whl", "has_sig": false, "md5_digest": "af8ec5c9019133c0c9bcc6903c1ce44c", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 34816, "upload_time": "2019-02-03T13:20:15", "url": "https://files.pythonhosted.org/packages/d3/e4/e6ef86b494ae855496a76ff5c929b7dd9e7437838f2e5e0532c41263c4df/opentmi_client-0.5.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "c781ea028a66769584d37c2470ad53fa", "sha256": "906f6d355462885f4b754e3a21e1ff3d2983e4c950cc05a35b23e69496f012a1" }, "downloads": -1, "filename": "opentmi_client-0.5.0.tar.gz", "has_sig": false, "md5_digest": "c781ea028a66769584d37c2470ad53fa", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 28329, "upload_time": "2019-02-03T13:20:17", "url": "https://files.pythonhosted.org/packages/a0/27/5092c0d533d876f5118dec19be60e0956a87d3a03e6f4d8797970ab4486a/opentmi_client-0.5.0.tar.gz" } ] }