Jan Cach | a2047ea | 2017-11-16 14:15:51 +0100 | [diff] [blame] | 1 | {%- from "opencontrail/map.jinja" import test with context %} |
| 2 | {%- if test.enabled %} |
| 3 | |
| 4 | opencontrail_test_packages: |
| 5 | pkg.installed: |
| 6 | - names: {{ test.pkgs }} |
| 7 | - force_yes: True |
| 8 | |
| 9 | install_python_packages: |
| 10 | pip.installed: |
| 11 | - names: |
| 12 | - pip |
| 13 | - tox |
| 14 | - setuptools |
| 15 | - require: |
| 16 | - pkg: opencontrail_test_packages |
| 17 | |
| 18 | install_vapor_and_dependencies: |
| 19 | pip.installed: |
| 20 | - requirements: salt://opencontrail/files/test_files/requirements.txt |
| 21 | - require: |
| 22 | - pip: install_python_packages |
| 23 | |
| 24 | {{ test.working_dir }}: |
| 25 | file.directory: |
| 26 | - user: root |
| 27 | - group: root |
| 28 | - dir_mode: 755 |
| 29 | - require: |
| 30 | - pip: install_vapor_and_dependencies |
| 31 | |
| 32 | clone_fuel_plugin_contrail: |
| 33 | git.latest: |
| 34 | - name: https://github.com/openstack/fuel-plugin-contrail.git |
| 35 | - target: {{ test.working_dir }}/fuel-plugin-contrail |
| 36 | - require: |
| 37 | - file: {{ test.working_dir }} |
| 38 | |
| 39 | {{ test.working_dir }}/fuel-plugin-contrail/plugin_test/vapor/roles.yaml: |
| 40 | file.managed: |
| 41 | - source: salt://opencontrail/files/test_files/roles.yaml |
| 42 | - user: root |
| 43 | - group: root |
| 44 | - template: jinja |
| 45 | - require: |
| 46 | - git: clone_fuel_plugin_contrail |
| 47 | |
| 48 | {{ test.working_dir }}/fuel-plugin-contrail/plugin_test/vapor/exports.sh: |
| 49 | file.managed: |
| 50 | - source: salt://opencontrail/files/test_files/exports.sh |
| 51 | - user: root |
| 52 | - group: root |
| 53 | - template: jinja |
| 54 | - require: |
| 55 | - git: clone_fuel_plugin_contrail |
| 56 | |
| 57 | {{ test.working_dir }}/fuel-plugin-contrail/plugin_test/vapor/os_faults.json: |
| 58 | file.managed: |
| 59 | - source: salt://opencontrail/files/test_files/os_faults.json |
| 60 | - user: root |
| 61 | - group: root |
| 62 | - require: |
| 63 | - git: clone_fuel_plugin_contrail |
| 64 | |
| 65 | {{ test.working_dir }}/fuel-plugin-contrail/plugin_test/vapor/pytest.ini: |
| 66 | file.managed: |
| 67 | - source: salt://opencontrail/files/test_files/pytest.ini |
| 68 | - user: root |
| 69 | - group: root |
| 70 | - require: |
| 71 | - git: clone_fuel_plugin_contrail |
| 72 | |
| 73 | {{ test.working_dir }}/fuel-plugin-contrail/plugin_test/vapor/requirements.txt: |
| 74 | file.managed: |
| 75 | - source: salt://opencontrail/files/test_files/requirements.txt |
| 76 | - user: root |
| 77 | - group: root |
| 78 | - require: |
| 79 | - git: clone_fuel_plugin_contrail |
| 80 | |
| 81 | {{ test.working_dir }}/fuel-plugin-contrail/plugin_test/vapor/vapor/conftest.py: |
| 82 | file.managed: |
| 83 | - source: salt://opencontrail/files/test_files/conftest.py |
| 84 | - user: root |
| 85 | - group: root |
| 86 | - require: |
| 87 | - git: clone_fuel_plugin_contrail |
| 88 | |
| 89 | {{ test.working_dir }}/fuel-plugin-contrail/plugin_test/vapor/keystonerc: |
| 90 | file.managed: |
| 91 | - source: salt://opencontrail/files/test_files/keystonerc |
| 92 | - user: root |
| 93 | - group: root |
| 94 | - template: jinja |
| 95 | - require: |
| 96 | - git: clone_fuel_plugin_contrail |
| 97 | |
| 98 | {{ test.working_dir }}/fuel-plugin-contrail/plugin_test/vapor/keystonercv3: |
| 99 | file.managed: |
| 100 | - source: salt://opencontrail/files/test_files/keystonercv3 |
| 101 | - user: root |
| 102 | - group: root |
| 103 | - template: jinja |
| 104 | - require: |
| 105 | - git: clone_fuel_plugin_contrail |
| 106 | |
| 107 | {%- endif %} |