Bläddra i källkod

docs(readme): update testing section

tags/v2.2.1
Nicolas Rodriguez 5 år sedan
förälder
incheckning
182f2169dc
1 ändrade filer med 26 tillägg och 11 borttagningar
  1. +26
    -11
      docs/README.rst

+ 26
- 11
docs/README.rst Visa fil



Linux testing is done with ``kitchen-salt``. Linux testing is done with ``kitchen-salt``.


``kitchen converge``
^^^^^^^^^^^^^^^^^^^^
Requirements
^^^^^^^^^^^^

* Ruby
* Docker

.. code-block:: bash

$ gem install bundler
$ bundle install
$ bin/kitchen test [platform]

Where ``[platform]`` is the platform name defined in ``kitchen.yml``,
e.g. ``debian-9-2019-2-py3``.

``bin/kitchen converge``
^^^^^^^^^^^^^^^^^^^^^^^^


Creates the docker instance and runs the ``template`` main state, ready for testing.
Creates the docker instance and runs the ``nginx`` main state, ready for testing.


``kitchen verify``
^^^^^^^^^^^^^^^^^^
``bin/kitchen verify``
^^^^^^^^^^^^^^^^^^^^^^


Runs the ``inspec`` tests on the actual instance. Runs the ``inspec`` tests on the actual instance.


``kitchen destroy``
^^^^^^^^^^^^^^^^^^^
``bin/kitchen destroy``
^^^^^^^^^^^^^^^^^^^^^^^


Removes the docker instance. Removes the docker instance.


``kitchen test``
^^^^^^^^^^^^^^^^
``bin/kitchen test``
^^^^^^^^^^^^^^^^^^^^


Runs all of the stages above in one go: i.e. ``destroy`` + ``converge`` + ``verify`` + ``destroy``. Runs all of the stages above in one go: i.e. ``destroy`` + ``converge`` + ``verify`` + ``destroy``.


``kitchen login``
^^^^^^^^^^^^^^^^^
``bin/kitchen login``
^^^^^^^^^^^^^^^^^^^^^


Gives you SSH access to the instance for manual testing. Gives you SSH access to the instance for manual testing.

Laddar…
Avbryt
Spara