avocado-framework-plugin-varianter-cit


Nameavocado-framework-plugin-varianter-cit JSON
Version 105.0 PyPI version JSON
download
home_pagehttp://avocado-framework.github.io/
SummaryVarianter with combinatorial capabilities
upload_time2024-05-07 18:47:36
maintainerNone
docs_urlNone
authorAvocado Developers
requires_pythonNone
licenseNone
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            .. _cit-varianter-plugin:

====================
CIT Varianter Plugin
====================

This plugin is an implementation of a "Combinatorial Interaction
Testing with Constraints" algorithm for the Avocado varianter
functionality.  It generates an optimal number of variants, which in
turn become different test scenarios.
To learn more about this algorithm, please take a look to the papers
listed below.

To install the Avocado CIT plugin from pip, use::

    $ sudo pip install avocado-framework-plugin-varianter-cit

To run the example below, use the test included in the avocado code ::

    $ git clone https://github.com/avocado-framework/avocado.git

Please refer to ``avocado/examples/varianter_cit/params.cit`` for an example
of a input file.

Input file format
=================

The following is the general structure of a input file::

  PARAMETERS
  Parameter_1 [Value_1,  Value_2, Value_3, Value_4]
  Parameter_2 [Value_1,  Value_2, Value_3, Value_4]
  Parameter_3 [Value_1,  Value_2, Value_3, Value_4]

  CONSTRAINTS
  Parameter_1 != Value_1 || Parameter_2 != Value_3
  Parameter_3 != Value_2 || Parameter_2 != Value_4 || Parameter_1 != Value_4

The input file has two parts, parameters and constraints.

Parameters
----------

* Each line represent one parameter.

* Each parameter has a name, and a list of values ​​inside brackets.

Constraints:
------------

* Constraints have to be in Conjunctive normal form.

* Constraints use these tree operands: ``!=, OR, AND``

* ``||`` represents operand ``OR`` and new line represents operand ``AND``.

* In the example, this is the logic formula ::

    ((P_1 != V1 OR P_2 != V_3) AND (P_3 != V_2 OR P_2 != V_4 OR P_1 != Value_4))

Usage
=====

.. note:: the algorithm employed here can be CPU intensive.  If you
          want more information on the progress of the combinatorial
          calculation, add ``--debug`` to a command line, such as
          ``avocado variants --debug --cit-parameter-file $PATH``

Cit varianter plugin runs with two parameters:

- ``--cit-parameter-file`` with path to the input file
- ``--cit-order-of-combinations`` with strength of combination (default is 2)

To see the variants generated by this demo implementation, execute::

    $ avocado variants --cit-parameter-file avocado/examples/varianter_cit/params.cit
    CIT Variants (28):
    Variant red-square-solid-plastic-anodic-6-4-4-2:    /
    Variant green-circle-gas-leather-cathodic-7-5-4-1:    /
    Variant green-triangle-liquid-leather-anodic-5-4-1-3:    /
    Variant green-square-liquid-plastic-anodic-3-1-4-5:    /
    Variant red-triangle-solid-leather-anodic-5-2-4-1:    /
    Variant black-triangle-gas-leather-anodic-7-1-1-2:    /
    Variant green-circle-solid-aluminum-cathodic-7-1-5-4:    /
    Variant red-square-gas-plastic-cathodic-6-3-5-3:    /
    Variant gold-triangle-solid-leather-anodic-6-5-1-4:    /
    Variant gold-triangle-gas-leather-anodic-3-2-5-2:    /
    Variant gold-square-gas-plastic-cathodic-5-1-1-1:    /
    Variant red-circle-gas-plastic-anodic-1-1-3-3:    /
    Variant red-circle-gas-aluminum-cathodic-3-3-1-5:    /
    Variant black-triangle-solid-plastic-cathodic-5-5-5-5:    /
    Variant gold-triangle-gas-leather-anodic-7-4-2-5:    /
    Variant black-triangle-gas-aluminum-cathodic-6-1-2-1:    /
    Variant gold-square-liquid-leather-cathodic-3-5-2-3:    /
    Variant black-square-solid-aluminum-cathodic-7-2-4-3:    /
    Variant black-circle-liquid-aluminum-anodic-1-4-5-1:    /
    Variant black-triangle-gas-leather-cathodic-7-3-3-1:    /
    Variant green-square-solid-aluminum-cathodic-1-3-2-2:    /
    Variant gold-triangle-gas-aluminum-anodic-1-3-4-4:    /
    Variant red-square-liquid-plastic-anodic-7-2-2-4:    /
    Variant gold-circle-liquid-aluminum-anodic-5-5-3-2:    /
    Variant red-triangle-gas-leather-anodic-1-5-1-5:    /
    Variant gold-circle-liquid-aluminum-cathodic-5-3-2-4:    /
    Variant black-square-solid-plastic-cathodic-3-4-3-4:    /
    Variant green-circle-liquid-plastic-cathodic-6-2-3-5:    /

.. note:: The exact variants generated are not guaranteed to be the same
          across executions.

You can enable more verbosity, making each variant to show its content::

    $ avocado variants --cit-parameter-file avocado/examples/varianter_cit/params.cit -c
    CIT Variants (28):

    Variant red-circle-solid-plastic-cathodic-6-3-3-1:    /
        /:coating  => cathodic
        /:color    => red
        /:material => plastic
        /:p10      => 1
        /:p7       => 6
        /:p8       => 3
        /:p9       => 3
        /:shape    => circle
        /:state    => solid

    Variant black-circle-liquid-aluminum-anodic-6-5-1-2:    /
        /:coating  => anodic
        /:color    => black
        /:material => aluminum
        /:p10      => 2
        /:p7       => 6
        /:p8       => 5
        /:p9       => 1
        /:shape    => circle
        /:state    => liquid

    ... Skip 26 more variants ...

To execute tests with those combinations use::

    $ avocado run avocado/examples/tests/passtest.py --cit-parameter-file avocado/examples/varianter_cit/params.cit
    JOB ID     : 6abd9e9f1ff9ed33a353ca8f3ef845cd4cc404a5
    JOB LOG    : $HOME/avocado/job-results/job-2018-07-23T08.46-6abd9e9/job.log
     (01/25) passtest.py:PassTest.test;black-circle-gas-plastic-anodic-3-3-5-5: PASS (0.04 s)
     (02/25) passtest.py:PassTest.test;gold-square-liquid-leather-anodic-3-2-1-4: PASS (0.03 s)
     (03/25) passtest.py:PassTest.test;green-square-gas-plastic-cathodic-3-5-4-1: PASS (0.04 s)
     (04/25) passtest.py:PassTest.test;gold-circle-solid-leather-anodic-6-4-4-2: PASS (0.04 s)
     (05/25) passtest.py:PassTest.test;green-triangle-liquid-aluminum-cathodic-7-4-5-1: PASS (0.04 s)
     (06/25) passtest.py:PassTest.test;black-circle-gas-plastic-cathodic-1-4-3-4: PASS (0.04 s)
     (07/25) passtest.py:PassTest.test;red-square-gas-leather-anodic-3-4-2-3: PASS (0.04 s)
     (08/25) passtest.py:PassTest.test;gold-triangle-solid-leather-anodic-1-3-2-1: PASS (0.04 s)
     (09/25) passtest.py:PassTest.test;green-circle-gas-plastic-cathodic-7-1-2-4: PASS (0.04 s)
     (10/25) passtest.py:PassTest.test;green-triangle-gas-aluminum-cathodic-6-2-2-5: PASS (0.04 s)
     (11/25) passtest.py:PassTest.test;black-circle-liquid-plastic-cathodic-5-5-2-2: PASS (0.03 s)
     (12/25) passtest.py:PassTest.test;red-square-solid-aluminum-anodic-5-2-3-1: PASS (0.04 s)
     (13/25) passtest.py:PassTest.test;gold-square-solid-leather-anodic-7-5-3-5: PASS (0.04 s)
     (14/25) passtest.py:PassTest.test;green-triangle-solid-leather-anodic-1-5-1-3: PASS (0.04 s)
     (15/25) passtest.py:PassTest.test;black-circle-liquid-leather-cathodic-6-1-1-1: PASS (0.04 s)
     (16/25) passtest.py:PassTest.test;red-triangle-liquid-plastic-anodic-6-3-3-3: PASS (0.04 s)
     (17/25) passtest.py:PassTest.test;green-triangle-solid-plastic-cathodic-5-3-4-4: PASS (0.04 s)
     (18/25) passtest.py:PassTest.test;red-square-liquid-aluminum-anodic-6-5-5-4: PASS (0.04 s)
     (19/25) passtest.py:PassTest.test;red-square-gas-aluminum-cathodic-7-3-1-2: PASS (0.04 s)
     (20/25) passtest.py:PassTest.test;red-square-liquid-aluminum-anodic-1-1-4-5: PASS (0.04 s)
     (21/25) passtest.py:PassTest.test;gold-circle-gas-plastic-anodic-5-4-1-5: PASS (0.04 s)
     (22/25) passtest.py:PassTest.test;gold-circle-solid-leather-anodic-5-1-5-3: PASS (0.04 s)
     (23/25) passtest.py:PassTest.test;red-circle-liquid-plastic-cathodic-1-2-5-2: PASS (0.04 s)
     (24/25) passtest.py:PassTest.test;green-triangle-solid-aluminum-anodic-3-1-3-2: PASS (0.04 s)
     (25/25) passtest.py:PassTest.test;black-circle-solid-aluminum-cathodic-7-2-4-3: PASS (0.03 s)
    RESULTS    : PASS 25 | ERROR 0 | FAIL 0 | SKIP 0 | WARN 0 | INTERRUPT 0 | CANCEL 0
    JOB TIME   : 1.21 s
    JOB HTML   : $HOME/avocado/job-results/job-2018-07-23T08.46-6abd9e9/results.html

Publications
============

The publication by Ahmed, Bestoun S., Kamal Z. Zamli, and Chee Peng
Lim, entitled `“Application of particle swarm optimization to uniform
and variable strength covering array construction”
<https://www.sciencedirect.com/science/article/pii/S1568494611004716>`__,
Applied Soft Computing, 12(4), 2012, pp. 1330-1347, contains the basis
for the algorithm and implementation of this feature.

Additionally, the publication by Bestoun S. Ahmed, Amador Pahim,
Cleber R. Rosa Junior, D. Richard Kuhn and Miroslav Bures, entitled
`"Towards an Automated Unified Framework to Run Applications for
Combinatorial Interaction Testing"
<https://arxiv.org/pdf/1903.05387.pdf>`__, contain a practical use
case of this software.

            

Raw data

            {
    "_id": null,
    "home_page": "http://avocado-framework.github.io/",
    "name": "avocado-framework-plugin-varianter-cit",
    "maintainer": null,
    "docs_url": null,
    "requires_python": null,
    "maintainer_email": null,
    "keywords": null,
    "author": "Avocado Developers",
    "author_email": "avocado-devel@redhat.com",
    "download_url": "https://files.pythonhosted.org/packages/89/0a/81071b8b135dd1902c87753965ef2906c1b57078fc50d118044a82b8071b/avocado_framework_plugin_varianter_cit-105.0.tar.gz",
    "platform": null,
    "description": ".. _cit-varianter-plugin:\n\n====================\nCIT Varianter Plugin\n====================\n\nThis plugin is an implementation of a \"Combinatorial Interaction\nTesting with Constraints\" algorithm for the Avocado varianter\nfunctionality.  It generates an optimal number of variants, which in\nturn become different test scenarios.\nTo learn more about this algorithm, please take a look to the papers\nlisted below.\n\nTo install the Avocado CIT plugin from pip, use::\n\n    $ sudo pip install avocado-framework-plugin-varianter-cit\n\nTo run the example below, use the test included in the avocado code ::\n\n    $ git clone https://github.com/avocado-framework/avocado.git\n\nPlease refer to ``avocado/examples/varianter_cit/params.cit`` for an example\nof a input file.\n\nInput file format\n=================\n\nThe following is the general structure of a input file::\n\n  PARAMETERS\n  Parameter_1 [Value_1,  Value_2, Value_3, Value_4]\n  Parameter_2 [Value_1,  Value_2, Value_3, Value_4]\n  Parameter_3 [Value_1,  Value_2, Value_3, Value_4]\n\n  CONSTRAINTS\n  Parameter_1 != Value_1 || Parameter_2 != Value_3\n  Parameter_3 != Value_2 || Parameter_2 != Value_4 || Parameter_1 != Value_4\n\nThe input file has two parts, parameters and constraints.\n\nParameters\n----------\n\n* Each line represent one parameter.\n\n* Each parameter has a name, and a list of values \u200b\u200binside brackets.\n\nConstraints:\n------------\n\n* Constraints have to be in Conjunctive normal form.\n\n* Constraints use these tree operands: ``!=, OR, AND``\n\n* ``||`` represents operand ``OR`` and new line represents operand ``AND``.\n\n* In the example, this is the logic formula ::\n\n    ((P_1 != V1 OR P_2 != V_3) AND (P_3 != V_2 OR P_2 != V_4 OR P_1 != Value_4))\n\nUsage\n=====\n\n.. note:: the algorithm employed here can be CPU intensive.  If you\n          want more information on the progress of the combinatorial\n          calculation, add ``--debug`` to a command line, such as\n          ``avocado variants --debug --cit-parameter-file $PATH``\n\nCit varianter plugin runs with two parameters:\n\n- ``--cit-parameter-file`` with path to the input file\n- ``--cit-order-of-combinations`` with strength of combination (default is 2)\n\nTo see the variants generated by this demo implementation, execute::\n\n    $ avocado variants --cit-parameter-file avocado/examples/varianter_cit/params.cit\n    CIT Variants (28):\n    Variant red-square-solid-plastic-anodic-6-4-4-2:    /\n    Variant green-circle-gas-leather-cathodic-7-5-4-1:    /\n    Variant green-triangle-liquid-leather-anodic-5-4-1-3:    /\n    Variant green-square-liquid-plastic-anodic-3-1-4-5:    /\n    Variant red-triangle-solid-leather-anodic-5-2-4-1:    /\n    Variant black-triangle-gas-leather-anodic-7-1-1-2:    /\n    Variant green-circle-solid-aluminum-cathodic-7-1-5-4:    /\n    Variant red-square-gas-plastic-cathodic-6-3-5-3:    /\n    Variant gold-triangle-solid-leather-anodic-6-5-1-4:    /\n    Variant gold-triangle-gas-leather-anodic-3-2-5-2:    /\n    Variant gold-square-gas-plastic-cathodic-5-1-1-1:    /\n    Variant red-circle-gas-plastic-anodic-1-1-3-3:    /\n    Variant red-circle-gas-aluminum-cathodic-3-3-1-5:    /\n    Variant black-triangle-solid-plastic-cathodic-5-5-5-5:    /\n    Variant gold-triangle-gas-leather-anodic-7-4-2-5:    /\n    Variant black-triangle-gas-aluminum-cathodic-6-1-2-1:    /\n    Variant gold-square-liquid-leather-cathodic-3-5-2-3:    /\n    Variant black-square-solid-aluminum-cathodic-7-2-4-3:    /\n    Variant black-circle-liquid-aluminum-anodic-1-4-5-1:    /\n    Variant black-triangle-gas-leather-cathodic-7-3-3-1:    /\n    Variant green-square-solid-aluminum-cathodic-1-3-2-2:    /\n    Variant gold-triangle-gas-aluminum-anodic-1-3-4-4:    /\n    Variant red-square-liquid-plastic-anodic-7-2-2-4:    /\n    Variant gold-circle-liquid-aluminum-anodic-5-5-3-2:    /\n    Variant red-triangle-gas-leather-anodic-1-5-1-5:    /\n    Variant gold-circle-liquid-aluminum-cathodic-5-3-2-4:    /\n    Variant black-square-solid-plastic-cathodic-3-4-3-4:    /\n    Variant green-circle-liquid-plastic-cathodic-6-2-3-5:    /\n\n.. note:: The exact variants generated are not guaranteed to be the same\n          across executions.\n\nYou can enable more verbosity, making each variant to show its content::\n\n    $ avocado variants --cit-parameter-file avocado/examples/varianter_cit/params.cit -c\n    CIT Variants (28):\n\n    Variant red-circle-solid-plastic-cathodic-6-3-3-1:    /\n        /:coating  => cathodic\n        /:color    => red\n        /:material => plastic\n        /:p10      => 1\n        /:p7       => 6\n        /:p8       => 3\n        /:p9       => 3\n        /:shape    => circle\n        /:state    => solid\n\n    Variant black-circle-liquid-aluminum-anodic-6-5-1-2:    /\n        /:coating  => anodic\n        /:color    => black\n        /:material => aluminum\n        /:p10      => 2\n        /:p7       => 6\n        /:p8       => 5\n        /:p9       => 1\n        /:shape    => circle\n        /:state    => liquid\n\n    ... Skip 26 more variants ...\n\nTo execute tests with those combinations use::\n\n    $ avocado run avocado/examples/tests/passtest.py --cit-parameter-file avocado/examples/varianter_cit/params.cit\n    JOB ID     : 6abd9e9f1ff9ed33a353ca8f3ef845cd4cc404a5\n    JOB LOG    : $HOME/avocado/job-results/job-2018-07-23T08.46-6abd9e9/job.log\n     (01/25) passtest.py:PassTest.test;black-circle-gas-plastic-anodic-3-3-5-5: PASS (0.04 s)\n     (02/25) passtest.py:PassTest.test;gold-square-liquid-leather-anodic-3-2-1-4: PASS (0.03 s)\n     (03/25) passtest.py:PassTest.test;green-square-gas-plastic-cathodic-3-5-4-1: PASS (0.04 s)\n     (04/25) passtest.py:PassTest.test;gold-circle-solid-leather-anodic-6-4-4-2: PASS (0.04 s)\n     (05/25) passtest.py:PassTest.test;green-triangle-liquid-aluminum-cathodic-7-4-5-1: PASS (0.04 s)\n     (06/25) passtest.py:PassTest.test;black-circle-gas-plastic-cathodic-1-4-3-4: PASS (0.04 s)\n     (07/25) passtest.py:PassTest.test;red-square-gas-leather-anodic-3-4-2-3: PASS (0.04 s)\n     (08/25) passtest.py:PassTest.test;gold-triangle-solid-leather-anodic-1-3-2-1: PASS (0.04 s)\n     (09/25) passtest.py:PassTest.test;green-circle-gas-plastic-cathodic-7-1-2-4: PASS (0.04 s)\n     (10/25) passtest.py:PassTest.test;green-triangle-gas-aluminum-cathodic-6-2-2-5: PASS (0.04 s)\n     (11/25) passtest.py:PassTest.test;black-circle-liquid-plastic-cathodic-5-5-2-2: PASS (0.03 s)\n     (12/25) passtest.py:PassTest.test;red-square-solid-aluminum-anodic-5-2-3-1: PASS (0.04 s)\n     (13/25) passtest.py:PassTest.test;gold-square-solid-leather-anodic-7-5-3-5: PASS (0.04 s)\n     (14/25) passtest.py:PassTest.test;green-triangle-solid-leather-anodic-1-5-1-3: PASS (0.04 s)\n     (15/25) passtest.py:PassTest.test;black-circle-liquid-leather-cathodic-6-1-1-1: PASS (0.04 s)\n     (16/25) passtest.py:PassTest.test;red-triangle-liquid-plastic-anodic-6-3-3-3: PASS (0.04 s)\n     (17/25) passtest.py:PassTest.test;green-triangle-solid-plastic-cathodic-5-3-4-4: PASS (0.04 s)\n     (18/25) passtest.py:PassTest.test;red-square-liquid-aluminum-anodic-6-5-5-4: PASS (0.04 s)\n     (19/25) passtest.py:PassTest.test;red-square-gas-aluminum-cathodic-7-3-1-2: PASS (0.04 s)\n     (20/25) passtest.py:PassTest.test;red-square-liquid-aluminum-anodic-1-1-4-5: PASS (0.04 s)\n     (21/25) passtest.py:PassTest.test;gold-circle-gas-plastic-anodic-5-4-1-5: PASS (0.04 s)\n     (22/25) passtest.py:PassTest.test;gold-circle-solid-leather-anodic-5-1-5-3: PASS (0.04 s)\n     (23/25) passtest.py:PassTest.test;red-circle-liquid-plastic-cathodic-1-2-5-2: PASS (0.04 s)\n     (24/25) passtest.py:PassTest.test;green-triangle-solid-aluminum-anodic-3-1-3-2: PASS (0.04 s)\n     (25/25) passtest.py:PassTest.test;black-circle-solid-aluminum-cathodic-7-2-4-3: PASS (0.03 s)\n    RESULTS    : PASS 25 | ERROR 0 | FAIL 0 | SKIP 0 | WARN 0 | INTERRUPT 0 | CANCEL 0\n    JOB TIME   : 1.21 s\n    JOB HTML   : $HOME/avocado/job-results/job-2018-07-23T08.46-6abd9e9/results.html\n\nPublications\n============\n\nThe publication by Ahmed, Bestoun S., Kamal Z. Zamli, and Chee Peng\nLim, entitled `\u201cApplication of particle swarm optimization to uniform\nand variable strength covering array construction\u201d\n<https://www.sciencedirect.com/science/article/pii/S1568494611004716>`__,\nApplied Soft Computing, 12(4), 2012, pp. 1330-1347, contains the basis\nfor the algorithm and implementation of this feature.\n\nAdditionally, the publication by Bestoun S. Ahmed, Amador Pahim,\nCleber R. Rosa Junior, D. Richard Kuhn and Miroslav Bures, entitled\n`\"Towards an Automated Unified Framework to Run Applications for\nCombinatorial Interaction Testing\"\n<https://arxiv.org/pdf/1903.05387.pdf>`__, contain a practical use\ncase of this software.\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "Varianter with combinatorial capabilities",
    "version": "105.0",
    "project_urls": {
        "Homepage": "http://avocado-framework.github.io/"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "80ff5c1ef21034b2765a7d9309e6fea7ef658629d6304cec008836c9f1da4804",
                "md5": "262d641cbc788f6337433e170952a4af",
                "sha256": "fb9db311a029351fc7c8f262f5b8ebbc9e739be28659a12e0e4140456e5c7ee0"
            },
            "downloads": -1,
            "filename": "avocado_framework_plugin_varianter_cit-105.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "262d641cbc788f6337433e170952a4af",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 15236,
            "upload_time": "2024-05-07T18:47:14",
            "upload_time_iso_8601": "2024-05-07T18:47:14.122237Z",
            "url": "https://files.pythonhosted.org/packages/80/ff/5c1ef21034b2765a7d9309e6fea7ef658629d6304cec008836c9f1da4804/avocado_framework_plugin_varianter_cit-105.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "890a81071b8b135dd1902c87753965ef2906c1b57078fc50d118044a82b8071b",
                "md5": "33ebe56a9c2032c60a9717c38556249e",
                "sha256": "5adaa871a30acae98388f47823521dfcf4da6d341b00e0bc492a5910b5b05dff"
            },
            "downloads": -1,
            "filename": "avocado_framework_plugin_varianter_cit-105.0.tar.gz",
            "has_sig": false,
            "md5_digest": "33ebe56a9c2032c60a9717c38556249e",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 13682,
            "upload_time": "2024-05-07T18:47:36",
            "upload_time_iso_8601": "2024-05-07T18:47:36.523576Z",
            "url": "https://files.pythonhosted.org/packages/89/0a/81071b8b135dd1902c87753965ef2906c1b57078fc50d118044a82b8071b/avocado_framework_plugin_varianter_cit-105.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-05-07 18:47:36",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "avocado-framework-plugin-varianter-cit"
}
        
Elapsed time: 0.33528s