ld-feature-patch


Nameld-feature-patch JSON
Version 1.0.0 PyPI version JSON
download
home_pagehttps://github.com/pymetrics/ld-feature-patch
SummaryPatch Launch Darkly feature flags for unit testing
upload_time2024-01-12 14:22:19
maintainer
docs_urlNone
authorChris Lawlor
requires_python>=3.5
licenseApache Software License 2.0
keywords launch darkly testing pytest unit test
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI
coveralls test coverage No coveralls.
            ================
LD Feature Patch
================


.. image:: https://img.shields.io/pypi/v/ld_patch.svg
        :target: https://pypi.python.org/pypi/ld_patch

.. image:: https://img.shields.io/travis/pymetrics/ld-feature-patch.svg
        :target: https://travis-ci.com/pymetrics/ld-feature-patch

.. image:: https://readthedocs.org/projects/ld-feature-patch/badge/?version=latest
        :target: https://ld-feature-patch.readthedocs.io/en/latest/
        :alt: Documentation Status



Patch `Launch Darkly`_ feature flags for unit testing


* Free software: Apache Software License 2.0
* Documentation: https://ld-feature-patch.readthedocs.io/en/latest/.


Usage
--------

.. code:: python

    from ld_patch import patch_feature

    @patch_feature("my.flag.key", True)
    def test_my_code():

        # Feature defaults to False
        show_feature = ldclient.variation(
            "my.flag.key",
            "test@example.com",
            False
        )

        # But patch_feature set it to True
        assert show_feature == True


Installation
------------

.. code:: bash

    python -m pip install ld-feature-patch

Credits
-------

This package was created with Cookiecutter_ and the `audreyr/cookiecutter-pypackage`_ project template.

.. _Cookiecutter: https://github.com/audreyr/cookiecutter
.. _`audreyr/cookiecutter-pypackage`: https://github.com/audreyr/cookiecutter-pypackage
.. _`Launch Darkly`: https://launchdarkly.com/


=======
History
=======

1.0.0 (2024-01-12)
------------------

* Drop support for Python 3.6. Add Python 3.10 - 3.12.

0.1.0 (2021-01-11)
------------------

* First release on PyPI.

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/pymetrics/ld-feature-patch",
    "name": "ld-feature-patch",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.5",
    "maintainer_email": "",
    "keywords": "Launch Darkly,testing,pytest,unit test",
    "author": "Chris Lawlor",
    "author_email": "chris@pymetrics.com",
    "download_url": "https://files.pythonhosted.org/packages/43/10/b0b19dba61d050af7922cbfaa5d8a87fffade21971b8cf76b6136b3befd9/ld-feature-patch-1.0.0.tar.gz",
    "platform": null,
    "description": "================\nLD Feature Patch\n================\n\n\n.. image:: https://img.shields.io/pypi/v/ld_patch.svg\n        :target: https://pypi.python.org/pypi/ld_patch\n\n.. image:: https://img.shields.io/travis/pymetrics/ld-feature-patch.svg\n        :target: https://travis-ci.com/pymetrics/ld-feature-patch\n\n.. image:: https://readthedocs.org/projects/ld-feature-patch/badge/?version=latest\n        :target: https://ld-feature-patch.readthedocs.io/en/latest/\n        :alt: Documentation Status\n\n\n\nPatch `Launch Darkly`_ feature flags for unit testing\n\n\n* Free software: Apache Software License 2.0\n* Documentation: https://ld-feature-patch.readthedocs.io/en/latest/.\n\n\nUsage\n--------\n\n.. code:: python\n\n    from ld_patch import patch_feature\n\n    @patch_feature(\"my.flag.key\", True)\n    def test_my_code():\n\n        # Feature defaults to False\n        show_feature = ldclient.variation(\n            \"my.flag.key\",\n            \"test@example.com\",\n            False\n        )\n\n        # But patch_feature set it to True\n        assert show_feature == True\n\n\nInstallation\n------------\n\n.. code:: bash\n\n    python -m pip install ld-feature-patch\n\nCredits\n-------\n\nThis package was created with Cookiecutter_ and the `audreyr/cookiecutter-pypackage`_ project template.\n\n.. _Cookiecutter: https://github.com/audreyr/cookiecutter\n.. _`audreyr/cookiecutter-pypackage`: https://github.com/audreyr/cookiecutter-pypackage\n.. _`Launch Darkly`: https://launchdarkly.com/\n\n\n=======\nHistory\n=======\n\n1.0.0 (2024-01-12)\n------------------\n\n* Drop support for Python 3.6. Add Python 3.10 - 3.12.\n\n0.1.0 (2021-01-11)\n------------------\n\n* First release on PyPI.\n",
    "bugtrack_url": null,
    "license": "Apache Software License 2.0",
    "summary": "Patch Launch Darkly feature flags for unit testing",
    "version": "1.0.0",
    "project_urls": {
        "Homepage": "https://github.com/pymetrics/ld-feature-patch"
    },
    "split_keywords": [
        "launch darkly",
        "testing",
        "pytest",
        "unit test"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "55c00b2258ace075a6513c642c77276e03a9aec4b5a92a307a4228e2a0431a12",
                "md5": "55d961e8658f0b3c402e5e79eefc08d4",
                "sha256": "871c8e84da1917a69d8fcffdfb8c63d855ecb6c0aad541e1b6ae9df2e1713013"
            },
            "downloads": -1,
            "filename": "ld_feature_patch-1.0.0-py2.py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "55d961e8658f0b3c402e5e79eefc08d4",
            "packagetype": "bdist_wheel",
            "python_version": "py2.py3",
            "requires_python": ">=3.5",
            "size": 4136,
            "upload_time": "2024-01-12T14:22:15",
            "upload_time_iso_8601": "2024-01-12T14:22:15.843569Z",
            "url": "https://files.pythonhosted.org/packages/55/c0/0b2258ace075a6513c642c77276e03a9aec4b5a92a307a4228e2a0431a12/ld_feature_patch-1.0.0-py2.py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "4310b0b19dba61d050af7922cbfaa5d8a87fffade21971b8cf76b6136b3befd9",
                "md5": "954fb042a2d5a81227ffb3c684185690",
                "sha256": "5e90af0e46a6c0d342083cbaf6534a0ce1249d0b834867458f77cfce4946aca0"
            },
            "downloads": -1,
            "filename": "ld-feature-patch-1.0.0.tar.gz",
            "has_sig": false,
            "md5_digest": "954fb042a2d5a81227ffb3c684185690",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.5",
            "size": 11287,
            "upload_time": "2024-01-12T14:22:19",
            "upload_time_iso_8601": "2024-01-12T14:22:19.175493Z",
            "url": "https://files.pythonhosted.org/packages/43/10/b0b19dba61d050af7922cbfaa5d8a87fffade21971b8cf76b6136b3befd9/ld-feature-patch-1.0.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-01-12 14:22:19",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "pymetrics",
    "github_project": "ld-feature-patch",
    "travis_ci": true,
    "coveralls": false,
    "github_actions": false,
    "tox": true,
    "lcname": "ld-feature-patch"
}
        
Elapsed time: 0.15968s