| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 1 | ####################################################################################### |
| 2 | # Copyright ETSI Contributors and Others. |
| 3 | # |
| 4 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | # you may not use this file except in compliance with the License. |
| 6 | # You may obtain a copy of the License at |
| 7 | # |
| 8 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | # |
| 10 | # Unless required by applicable law or agreed to in writing, software |
| 11 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or |
| 13 | # implied. |
| 14 | # See the License for the specific language governing permissions and |
| 15 | # limitations under the License. |
| 16 | ####################################################################################### |
| 17 | |
| 18 | [tox] |
| Gulsum Atici | 2f99505 | 2022-11-23 16:06:40 +0300 | [diff] [blame] | 19 | envlist = black, cover, flake8, pylint, safety |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 20 | |
| 21 | [tox:jenkins] |
| 22 | toxworkdir = /tmp/.tox |
| Mark Beierl | 437308b | 2022-07-14 09:41:20 -0400 | [diff] [blame] | 23 | setenv = XDG_CACHE_HOME=/tmp/.cache |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 24 | |
| 25 | [testenv] |
| 26 | usedevelop = True |
| Gulsum Atici | a264b7a | 2023-05-09 14:57:22 +0300 | [diff] [blame] | 27 | basepython = python3.10 |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 28 | setenv = VIRTUAL_ENV={envdir} |
| 29 | PYTHONDONTWRITEBYTECODE = 1 |
| 30 | deps = -r{toxinidir}/requirements.txt |
| 31 | parallel_show_output = true |
| 32 | |
| 33 | |
| 34 | ####################################################################################### |
| sousaedu | 1077bbd | 2021-04-15 01:18:59 +0200 | [diff] [blame] | 35 | [testenv:release_notes] |
| 36 | deps = reno |
| 37 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 38 | allowlist_externals = bash |
| sousaedu | 1077bbd | 2021-04-15 01:18:59 +0200 | [diff] [blame] | 39 | commands = |
| 40 | reno new {posargs:new_feature} |
| sousaedu | 8849fb8 | 2022-01-25 14:11:04 +0000 | [diff] [blame] | 41 | bash -c "sed -i -e '1 e head -16 tox.ini' releasenotes/notes/{posargs:new_feature}*.yaml" |
| sousaedu | 1077bbd | 2021-04-15 01:18:59 +0200 | [diff] [blame] | 42 | |
| 43 | |
| 44 | ####################################################################################### |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 45 | [testenv:black] |
| garciadeblas | aca8cb5 | 2023-12-21 16:28:15 +0100 | [diff] [blame] | 46 | deps = black==24.1.1 |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 47 | skip_install = true |
| 48 | commands = |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 49 | black --check --diff NG-RO |
| 50 | black --check --diff RO-plugin |
| 51 | black --check --diff RO-SDN-arista_cloudvision |
| 52 | black --check --diff RO-SDN-dpb |
| 53 | black --check --diff RO-SDN-dynpac |
| 54 | black --check --diff RO-SDN-floodlight_openflow |
| 55 | black --check --diff RO-SDN-ietfl2vpn |
| 56 | black --check --diff RO-SDN-juniper_contrail |
| 57 | black --check --diff RO-SDN-odl_openflow |
| 58 | black --check --diff RO-SDN-onos_openflow |
| 59 | black --check --diff RO-SDN-onos_vpls |
| gifrerenom | 0e51779 | 2023-04-18 16:38:42 +0000 | [diff] [blame] | 60 | black --check --diff RO-SDN-tapi |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 61 | black --check --diff RO-VIM-aws |
| 62 | black --check --diff RO-VIM-azure |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 63 | black --check --diff RO-VIM-openstack |
| 64 | black --check --diff RO-VIM-openvim |
| 65 | black --check --diff RO-VIM-vmware |
| lloretgalleg | 6af6f6d | 2025-03-04 11:37:14 +0000 | [diff] [blame] | 66 | black --check --diff RO-VIM-vcenter |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 67 | black --check --diff RO-VIM-gcp |
| 68 | black --check --diff integration-tests |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 69 | |
| 70 | |
| 71 | ####################################################################################### |
| 72 | [testenv:cover] |
| 73 | deps = {[testenv]deps} |
| 74 | -r{toxinidir}/requirements-dev.txt |
| 75 | -r{toxinidir}/requirements-test.txt |
| 76 | skip_install = true |
| garciadeblas | 3822010 | 2023-02-13 17:48:32 +0100 | [diff] [blame] | 77 | allowlist_externals = sh |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 78 | commands = |
| 79 | sh -c 'rm -f nosetests.xml' |
| 80 | coverage erase |
| 81 | # NG-RO |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 82 | nose2 -C --coverage NG-RO/osm_ng_ro -s NG-RO/osm_ng_ro |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 83 | sh -c 'mv .coverage .coverage_ng_ro' |
| 84 | # RO-plugin |
| aticig | 562623c | 2022-03-31 22:03:33 +0300 | [diff] [blame] | 85 | # nose2 -C --coverage RO-plugin/osm_ro_plugin -s RO-plugin/osm_ro_plugin |
| 86 | # sh -c 'mv .coverage .coverage_ro_plugin' |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 87 | # RO-SDN-arista_cloudvision |
| aticig | 562623c | 2022-03-31 22:03:33 +0300 | [diff] [blame] | 88 | # nose2 -C --coverage RO-SDN-arista_cloudvision/osm_rosdn_arista_cloudvision -s RO-SDN-arista_cloudvision/osm_rosdn_arista_cloudvision |
| 89 | # sh -c 'mv .coverage .coverage_rosdn_arista_cloudvision' |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 90 | # RO-SDN-dpb |
| aticig | 562623c | 2022-03-31 22:03:33 +0300 | [diff] [blame] | 91 | # nose2 -C --coverage RO-SDN-dpb/osm_rosdn_dpb -s RO-SDN-dpb/osm_rosdn_dpb |
| 92 | # sh -c 'mv .coverage .coverage_rosdn_dpb' |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 93 | # RO-SDN-dynpac |
| aticig | 562623c | 2022-03-31 22:03:33 +0300 | [diff] [blame] | 94 | # nose2 -C --coverage RO-SDN-dynpac/osm_rosdn_dynpac -s RO-SDN-dynpac/osm_rosdn_dynpac |
| 95 | # sh -c 'mv .coverage .coverage_rosdn_dynpac' |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 96 | # RO-SDN-floodlight_openflow |
| aticig | 562623c | 2022-03-31 22:03:33 +0300 | [diff] [blame] | 97 | # nose2 -C --coverage RO-SDN-floodlight_openflow/osm_rosdn_floodlightof -s RO-SDN-floodlight_openflow/osm_rosdn_floodlightof |
| 98 | # sh -c 'mv .coverage .coverage_rosdn_floodlightof' |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 99 | # RO-SDN-ietfl2vpn |
| aticig | 562623c | 2022-03-31 22:03:33 +0300 | [diff] [blame] | 100 | # nose2 -C --coverage RO-SDN-ietfl2vpn/osm_rosdn_ietfl2vpn -s RO-SDN-ietfl2vpn/osm_rosdn_ietfl2vpn |
| 101 | # sh -c 'mv .coverage .coverage_rosdn_ietfl2vpn' |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 102 | # RO-SDN-juniper_contrail |
| aticig | 409d5af | 2022-07-29 14:27:16 +0300 | [diff] [blame] | 103 | nose2 -C --coverage RO-SDN-juniper_contrail/osm_rosdn_juniper_contrail -s RO-SDN-juniper_contrail/osm_rosdn_juniper_contrail |
| 104 | sh -c 'mv .coverage .coverage_rosdn_juniper_contrail' |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 105 | # RO-SDN-odl_openflow |
| aticig | 562623c | 2022-03-31 22:03:33 +0300 | [diff] [blame] | 106 | # nose2 -C --coverage RO-SDN-odl_openflow/osm_rosdn_odlof -s RO-SDN-odl_openflow/osm_rosdn_odlof |
| 107 | # sh -c 'mv .coverage .coverage_rosdn_odlof' |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 108 | # RO-SDN-onos_openflow |
| aticig | 562623c | 2022-03-31 22:03:33 +0300 | [diff] [blame] | 109 | # nose2 -C --coverage RO-SDN-onos_openflow/osm_rosdn_onosof -s RO-SDN-onos_openflow/osm_rosdn_onosof |
| 110 | # sh -c 'mv .coverage .coverage_rosdn_onosof' |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 111 | # RO-SDN-onos_vpls |
| aticig | 562623c | 2022-03-31 22:03:33 +0300 | [diff] [blame] | 112 | # nose2 -C --coverage RO-SDN-onos_vpls/osm_rosdn_onos_vpls -s RO-SDN-onos_vpls/osm_rosdn_onos_vpls |
| 113 | # sh -c 'mv .coverage .coverage_rosdn_onos_vpls' |
| gifrerenom | 0e51779 | 2023-04-18 16:38:42 +0000 | [diff] [blame] | 114 | # RO-SDN-tapi |
| 115 | nose2 -C --coverage RO-SDN-tapi/osm_rosdn_tapi -s RO-SDN-tapi/osm_rosdn_tapi |
| 116 | sh -c 'mv .coverage .coverage_rosdn_tapi' |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 117 | # RO-VIM-aws |
| aticig | 562623c | 2022-03-31 22:03:33 +0300 | [diff] [blame] | 118 | # nose2 -C --coverage RO-VIM-aws/osm_rovim_aws -s RO-VIM-aws/osm_rovim_aws |
| 119 | # sh -c 'mv .coverage .coverage_rovim_aws' |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 120 | # RO-VIM-azure |
| aticig | 562623c | 2022-03-31 22:03:33 +0300 | [diff] [blame] | 121 | # nose2 -C --coverage RO-VIM-azure/osm_rovim_azure -s RO-VIM-azure/osm_rovim_azure |
| 122 | # sh -c 'mv .coverage .coverage_rovim_azure' |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 123 | # RO-VIM-openstack |
| aticig | 562623c | 2022-03-31 22:03:33 +0300 | [diff] [blame] | 124 | nose2 -C --coverage RO-VIM-openstack/osm_rovim_openstack -s RO-VIM-openstack/osm_rovim_openstack |
| 125 | sh -c 'mv .coverage .coverage_rovim_openstack' |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 126 | # RO-VIM-openvim |
| aticig | 562623c | 2022-03-31 22:03:33 +0300 | [diff] [blame] | 127 | # nose2 -C --coverage RO-VIM-openvim/osm_rovim_openvim -s RO-VIM-openvim/osm_rovim_openvim |
| 128 | # sh -c 'mv .coverage .coverage_rovim_openvim' |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 129 | # RO-VIM-vmware |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 130 | # nose2 -C --coverage RO-VIM-vmware/osm_rovim_vmware -s RO-VIM-vmware/osm_rovim_vmware |
| 131 | # sh -c 'mv .coverage .coverage_rovim_vmware' |
| gallardo | 34aa3a9 | 2021-10-08 11:50:00 +0000 | [diff] [blame] | 132 | # RO-VIM-gcp |
| aticig | 562623c | 2022-03-31 22:03:33 +0300 | [diff] [blame] | 133 | # nose2 -C --coverage RO-VIM-gcp/osm_rovim_gcp -s RO-VIM-gcp/osm_rovim_gcp |
| 134 | # sh -c 'mv .coverage .coverage_rovim_gcp' |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 135 | # Combine results and generate reports |
| gifrerenom | 0e51779 | 2023-04-18 16:38:42 +0000 | [diff] [blame] | 136 | # coverage combine .coverage_ng_ro .coverage_ro_plugin .coverage_rosdn_arista_cloudvision .coverage_rosdn_dpb .coverage_rosdn_dynpac .coverage_rosdn_floodlightof .coverage_rosdn_ietfl2vpn .coverage_rosdn_juniper_contrail .coverage_rosdn_odlof .coverage_rosdn_onos_vpls .coverage_rosdn_onosof .coverage_rosdn_tapi .coverage_rovim_aws .coverage_rovim_azure .coverage_rovim_openvim .coverage_rovim_gcp # .coverage_rovim_openstack .coverage_rovim_vmware |
| aticig | 409d5af | 2022-07-29 14:27:16 +0300 | [diff] [blame] | 137 | coverage combine .coverage_ng_ro .coverage_rovim_openstack .coverage_rosdn_juniper_contrail |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 138 | coverage report --omit='*tests*' |
| 139 | coverage html -d ./cover --omit='*tests*' |
| 140 | coverage xml -o coverage.xml --omit='*tests*' |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 141 | |
| 142 | |
| 143 | ####################################################################################### |
| 144 | [testenv:flake8] |
| sousaedu | 049cbb1 | 2022-01-05 11:39:35 +0000 | [diff] [blame] | 145 | deps = |
| garciadeblas | aca8cb5 | 2023-12-21 16:28:15 +0100 | [diff] [blame] | 146 | flake8==7.0.0 |
| sousaedu | 049cbb1 | 2022-01-05 11:39:35 +0000 | [diff] [blame] | 147 | flake8-import-order |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 148 | skip_install = true |
| 149 | commands = |
| sousaedu | 686720b | 2021-11-24 02:16:11 +0000 | [diff] [blame] | 150 | flake8 NG-RO/osm_ng_ro/ NG-RO/setup.py |
| sousaedu | 049cbb1 | 2022-01-05 11:39:35 +0000 | [diff] [blame] | 151 | flake8 RO-plugin/osm_ro_plugin/ RO-plugin/setup.py |
| 152 | flake8 RO-SDN-arista_cloudvision/osm_rosdn_arista_cloudvision/ RO-SDN-arista_cloudvision/setup.py |
| 153 | flake8 RO-SDN-dpb/osm_rosdn_dpb/ RO-SDN-dpb/setup.py |
| 154 | flake8 RO-SDN-dynpac/osm_rosdn_dynpac/ RO-SDN-dynpac/setup.py |
| 155 | flake8 RO-SDN-floodlight_openflow/osm_rosdn_floodlightof/ RO-SDN-floodlight_openflow/setup.py |
| 156 | flake8 RO-SDN-ietfl2vpn/osm_rosdn_ietfl2vpn/ RO-SDN-ietfl2vpn/setup.py |
| 157 | flake8 RO-SDN-juniper_contrail/osm_rosdn_juniper_contrail/ RO-SDN-juniper_contrail/setup.py |
| 158 | flake8 RO-SDN-odl_openflow/osm_rosdn_odlof/ RO-SDN-odl_openflow/setup.py |
| 159 | flake8 RO-SDN-onos_openflow/osm_rosdn_onosof/ RO-SDN-onos_openflow/setup.py |
| 160 | flake8 RO-SDN-onos_vpls/osm_rosdn_onos_vpls/ RO-SDN-onos_vpls/setup.py |
| gifrerenom | 0e51779 | 2023-04-18 16:38:42 +0000 | [diff] [blame] | 161 | flake8 RO-SDN-tapi/osm_rosdn_tapi/ RO-SDN-tapi/setup.py |
| sousaedu | 049cbb1 | 2022-01-05 11:39:35 +0000 | [diff] [blame] | 162 | flake8 RO-VIM-aws/osm_rovim_aws/ RO-VIM-aws/setup.py |
| 163 | flake8 RO-VIM-azure/osm_rovim_azure/ RO-VIM-azure/setup.py |
| 164 | flake8 RO-VIM-openstack/osm_rovim_openstack/ RO-VIM-openstack/setup.py |
| 165 | flake8 RO-VIM-openvim/osm_rovim_openvim/ RO-VIM-openvim/setup.py |
| lloretgalleg | 6af6f6d | 2025-03-04 11:37:14 +0000 | [diff] [blame] | 166 | flake8 RO-VIM-vcenter/osm_rovim_vcenter/ RO-VIM-vcenter/setup.py |
| sousaedu | 049cbb1 | 2022-01-05 11:39:35 +0000 | [diff] [blame] | 167 | flake8 RO-VIM-vmware/osm_rovim_vmware/vimconn_vmware.py RO-VIM-vmware/osm_rovim_vmware/tests/test_vimconn_vmware.py RO-VIM-vmware/setup.py |
| 168 | flake8 RO-VIM-gcp/osm_rovim_gcp/ RO-VIM-gcp/setup.py |
| 169 | flake8 integration-tests/ |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 170 | |
| 171 | |
| 172 | ####################################################################################### |
| 173 | [testenv:pylint] |
| 174 | deps = {[testenv]deps} |
| 175 | -r{toxinidir}/requirements-dev.txt |
| 176 | -r{toxinidir}/requirements-test.txt |
| garciadeblas | aca8cb5 | 2023-12-21 16:28:15 +0100 | [diff] [blame] | 177 | pylint==3.0.3 |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 178 | skip_install = true |
| 179 | commands = |
| Gulsum Atici | 2f99505 | 2022-11-23 16:06:40 +0300 | [diff] [blame] | 180 | pylint -E NG-RO/osm_ng_ro --disable=E1101 |
| 181 | pylint -E RO-plugin/osm_ro_plugin --disable=E1101 |
| garciadeblas | aca8cb5 | 2023-12-21 16:28:15 +0100 | [diff] [blame] | 182 | - pylint -E RO-SDN-arista_cloudvision/osm_rosdn_arista_cloudvision --disable=all |
| Gulsum Atici | 2f99505 | 2022-11-23 16:06:40 +0300 | [diff] [blame] | 183 | pylint -E RO-SDN-dpb/osm_rosdn_dpb |
| 184 | pylint -E RO-SDN-dynpac/osm_rosdn_dynpac --disable=E1101 |
| 185 | pylint -E RO-SDN-floodlight_openflow/osm_rosdn_floodlightof |
| 186 | pylint -E RO-SDN-ietfl2vpn/osm_rosdn_ietfl2vpn --disable=E1101 |
| 187 | pylint -E RO-SDN-juniper_contrail/osm_rosdn_juniper_contrail |
| 188 | pylint -E RO-SDN-odl_openflow/osm_rosdn_odlof |
| 189 | pylint -E RO-SDN-onos_openflow/osm_rosdn_onosof |
| 190 | pylint -E RO-SDN-onos_vpls/osm_rosdn_onos_vpls --disable=E1101 |
| gifrerenom | 0e51779 | 2023-04-18 16:38:42 +0000 | [diff] [blame] | 191 | pylint -E RO-SDN-tapi/osm_rosdn_tapi |
| Gulsum Atici | 2f99505 | 2022-11-23 16:06:40 +0300 | [diff] [blame] | 192 | pylint -E RO-VIM-aws/osm_rovim_aws |
| lloretgalleg | 6af6f6d | 2025-03-04 11:37:14 +0000 | [diff] [blame] | 193 | pylint -E RO-VIM-vcenter/osm_rovim_vcenter |
| garciadeblas | aca8cb5 | 2023-12-21 16:28:15 +0100 | [diff] [blame] | 194 | - pylint -E RO-VIM-azure/osm_rovim_azure --disable=all |
| Gulsum Atici | 2f99505 | 2022-11-23 16:06:40 +0300 | [diff] [blame] | 195 | pylint -E RO-VIM-openstack/osm_rovim_openstack --disable=E1101 |
| garciadeblas | aca8cb5 | 2023-12-21 16:28:15 +0100 | [diff] [blame] | 196 | - pylint -E RO-VIM-openvim/osm_rovim_openvim --disable=all |
| 197 | - pylint -E RO-VIM-vmware/osm_rovim_vmware --disable=all |
| Gulsum Atici | 2f99505 | 2022-11-23 16:06:40 +0300 | [diff] [blame] | 198 | pylint -E RO-VIM-gcp/osm_rovim_gcp --disable=E1101 |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 199 | |
| 200 | |
| 201 | ####################################################################################### |
| 202 | [testenv:safety] |
| 203 | setenv = |
| 204 | LC_ALL=C.UTF-8 |
| 205 | LANG=C.UTF-8 |
| 206 | deps = {[testenv]deps} |
| 207 | safety |
| 208 | skip_install = true |
| 209 | commands = |
| 210 | - safety check --full-report |
| 211 | |
| 212 | |
| 213 | ####################################################################################### |
| 214 | [testenv:pip-compile] |
| garciadeblas | f289193 | 2023-07-05 16:46:11 +0200 | [diff] [blame] | 215 | deps = pip-tools==6.13.0 |
| sousaedu | becd083 | 2021-04-08 00:16:18 +0200 | [diff] [blame] | 216 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 217 | allowlist_externals = bash |
| beierlm | 8348393 | 2022-01-13 13:21:53 -0500 | [diff] [blame] | 218 | [ |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 219 | commands = |
| beierlm | 8348393 | 2022-01-13 13:21:53 -0500 | [diff] [blame] | 220 | - bash -c "for file in requirements*.in ; do \ |
| 221 | UNSAFE="" ; \ |
| 222 | if [[ $file =~ 'dist' ]] ; then UNSAFE='--allow-unsafe' ; fi ; \ |
| garciadeblas | f289193 | 2023-07-05 16:46:11 +0200 | [diff] [blame] | 223 | pip-compile --resolver=backtracking -rU --no-header $UNSAFE $file ;\ |
| sousaedu | becd083 | 2021-04-08 00:16:18 +0200 | [diff] [blame] | 224 | out=`echo $file | sed 's/.in/.txt/'` ; \ |
| 225 | sed -i -e '1 e head -16 tox.ini' $out ;\ |
| 226 | done" |
| beierlm | 8348393 | 2022-01-13 13:21:53 -0500 | [diff] [blame] | 227 | - bash -c "sed -i 's/.*RO-plugin/-e RO-plugin/g' requirements-test.txt" |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 228 | |
| 229 | |
| 230 | ####################################################################################### |
| 231 | [testenv:dist_ng_ro] |
| 232 | deps = {[testenv]deps} |
| 233 | -r{toxinidir}/requirements-dist.txt |
| 234 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 235 | allowlist_externals = sh |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 236 | changedir = {toxinidir}/NG-RO |
| 237 | commands = |
| 238 | sh -c 'rm -rf osm_ng_ro/requirements.txt deb_dist dist osm_ng_ro.egg-info osm_ng_ro*.tar.gz' |
| 239 | sh -c 'cp ../requirements.txt osm_ng_ro/requirements.txt' |
| 240 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 241 | sh -c 'cd deb_dist/osm-ng-ro*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 242 | |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 243 | |
| 244 | ####################################################################################### |
| 245 | [testenv:dist_ro_plugin] |
| 246 | deps = {[testenv]deps} |
| 247 | -r{toxinidir}/requirements-dist.txt |
| 248 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 249 | allowlist_externals = sh |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 250 | changedir = {toxinidir}/RO-plugin |
| 251 | commands = |
| 252 | sh -c 'rm -rf deb_dist dist osm_ro_plugin.egg-info osm_ro_plugin*.tar.gz' |
| 253 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 254 | sh -c 'cd deb_dist/osm-ro-plugin*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 255 | |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 256 | |
| 257 | ####################################################################################### |
| 258 | [testenv:dist_ro_sdn_arista_cloudvision] |
| 259 | deps = {[testenv]deps} |
| 260 | -r{toxinidir}/requirements-dist.txt |
| 261 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 262 | allowlist_externals = sh |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 263 | changedir = {toxinidir}/RO-SDN-arista_cloudvision |
| 264 | commands = |
| 265 | sh -c 'rm -rf deb_dist dist osm_rosdn_arista_cloudvision.egg-info osm_rosdn_arista_cloudvision*.tar.gz' |
| 266 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 267 | sh -c 'cd deb_dist/osm-rosdn-arista-cloudvision*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 268 | |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 269 | |
| 270 | ####################################################################################### |
| 271 | [testenv:dist_ro_sdn_dpb] |
| 272 | deps = {[testenv]deps} |
| 273 | -r{toxinidir}/requirements-dist.txt |
| 274 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 275 | allowlist_externals = sh |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 276 | changedir = {toxinidir}/RO-SDN-dpb |
| 277 | commands = |
| 278 | sh -c 'rm -rf deb_dist dist osm_rosdn_dpb.egg-info osm_rosdn_dpb*.tar.gz' |
| 279 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 280 | sh -c 'cd deb_dist/osm-rosdn-dpb*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 281 | |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 282 | |
| 283 | ####################################################################################### |
| 284 | [testenv:dist_ro_sdn_dynpac] |
| 285 | deps = {[testenv]deps} |
| 286 | -r{toxinidir}/requirements-dist.txt |
| 287 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 288 | allowlist_externals = sh |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 289 | changedir = {toxinidir}/RO-SDN-dynpac |
| 290 | commands = |
| 291 | sh -c 'rm -rf deb_dist dist osm_rosdn_dynpac.egg-info osm_rosdn_dynpac*.tar.gz' |
| 292 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 293 | sh -c 'cd deb_dist/osm-rosdn-dynpac*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 294 | |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 295 | |
| 296 | ####################################################################################### |
| 297 | [testenv:dist_ro_sdn_floodlight_of] |
| 298 | deps = {[testenv]deps} |
| 299 | -r{toxinidir}/requirements-dist.txt |
| 300 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 301 | allowlist_externals = sh |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 302 | changedir = {toxinidir}/RO-SDN-floodlight_openflow |
| 303 | commands = |
| 304 | sh -c 'rm -rf deb_dist dist osm_rosdn_floodlightof.egg-info osm_rosdn_floodlightof*.tar.gz' |
| 305 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 306 | sh -c 'cd deb_dist/osm-rosdn-floodlightof*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 307 | |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 308 | |
| 309 | ####################################################################################### |
| 310 | [testenv:dist_ro_sdn_ietfl2vpn] |
| 311 | deps = {[testenv]deps} |
| 312 | -r{toxinidir}/requirements-dist.txt |
| 313 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 314 | allowlist_externals = sh |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 315 | changedir = {toxinidir}/RO-SDN-ietfl2vpn |
| 316 | commands = |
| 317 | sh -c 'rm -rf deb_dist dist osm_rosdn_ietfl2vpn.egg-info osm_rosdn_ietfl2vpn*.tar.gz' |
| 318 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 319 | sh -c 'cd deb_dist/osm-rosdn-ietfl2vpn*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 320 | |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 321 | |
| 322 | ####################################################################################### |
| 323 | [testenv:dist_ro_sdn_juniper_contrail] |
| 324 | deps = {[testenv]deps} |
| 325 | -r{toxinidir}/requirements-dist.txt |
| 326 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 327 | allowlist_externals = sh |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 328 | changedir = {toxinidir}/RO-SDN-juniper_contrail |
| 329 | commands = |
| 330 | sh -c 'rm -rf deb_dist dist osm_rosdn_juniper_contrail.egg-info osm_rosdn_juniper_contrail*.tar.gz' |
| 331 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 332 | sh -c 'cd deb_dist/osm-rosdn-juniper-contrail*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 333 | |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 334 | |
| 335 | ####################################################################################### |
| 336 | [testenv:dist_ro_sdn_odl_of] |
| 337 | deps = {[testenv]deps} |
| 338 | -r{toxinidir}/requirements-dist.txt |
| 339 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 340 | allowlist_externals = sh |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 341 | changedir = {toxinidir}/RO-SDN-odl_openflow |
| 342 | commands = |
| 343 | sh -c 'rm -rf deb_dist dist osm_rosdn_odlof.egg-info osm_rosdn_odlof*.tar.gz' |
| 344 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 345 | sh -c 'cd deb_dist/osm-rosdn-odlof*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 346 | |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 347 | |
| 348 | ####################################################################################### |
| 349 | [testenv:dist_ro_sdn_onos_of] |
| 350 | deps = {[testenv]deps} |
| 351 | -r{toxinidir}/requirements-dist.txt |
| 352 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 353 | allowlist_externals = sh |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 354 | changedir = {toxinidir}/RO-SDN-onos_openflow |
| 355 | commands = |
| 356 | sh -c 'rm -rf deb_dist dist osm_rosdn_onosof.egg-info osm_rosdn_onosof*.tar.gz' |
| 357 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 358 | sh -c 'cd deb_dist/osm-rosdn-onosof*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 359 | |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 360 | |
| 361 | ####################################################################################### |
| 362 | [testenv:dist_ro_sdn_onos_vpls] |
| 363 | deps = {[testenv]deps} |
| 364 | -r{toxinidir}/requirements-dist.txt |
| 365 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 366 | allowlist_externals = sh |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 367 | changedir = {toxinidir}/RO-SDN-onos_vpls |
| 368 | commands = |
| 369 | sh -c 'rm -rf deb_dist dist osm_rosdn_onos_vpls.egg-info osm_rosdn_onos_vpls*.tar.gz' |
| 370 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 371 | sh -c 'cd deb_dist/osm-rosdn-onos-vpls*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 372 | |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 373 | |
| 374 | ####################################################################################### |
| gifrerenom | 0e51779 | 2023-04-18 16:38:42 +0000 | [diff] [blame] | 375 | [testenv:dist_ro_sdn_tapi] |
| 376 | deps = {[testenv]deps} |
| 377 | -r{toxinidir}/requirements-dist.txt |
| 378 | skip_install = true |
| garciadeblas | abaa1e0 | 2023-09-28 23:15:11 +0200 | [diff] [blame] | 379 | allowlist_externals = sh |
| gifrerenom | 0e51779 | 2023-04-18 16:38:42 +0000 | [diff] [blame] | 380 | changedir = {toxinidir}/RO-SDN-tapi |
| 381 | commands = |
| 382 | sh -c 'rm -rf deb_dist dist osm_rosdn_tapi.egg-info osm_rosdn_tapi*.tar.gz' |
| 383 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 384 | sh -c 'cd deb_dist/osm-rosdn-tapi*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| 385 | |
| 386 | |
| 387 | ####################################################################################### |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 388 | [testenv:dist_ro_vim_aws] |
| 389 | deps = {[testenv]deps} |
| 390 | -r{toxinidir}/requirements-dist.txt |
| 391 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 392 | allowlist_externals = sh |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 393 | changedir = {toxinidir}/RO-VIM-aws |
| 394 | commands = |
| 395 | sh -c 'rm -rf deb_dist dist osm_rovim_aws.egg-info osm_rovim_aws*.tar.gz' |
| 396 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 397 | sh -c 'cd deb_dist/osm-rovim-aws*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 398 | |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 399 | |
| 400 | ####################################################################################### |
| 401 | [testenv:dist_ro_vim_azure] |
| 402 | deps = {[testenv]deps} |
| 403 | -r{toxinidir}/requirements-dist.txt |
| 404 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 405 | allowlist_externals = sh |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 406 | changedir = {toxinidir}/RO-VIM-azure |
| 407 | commands = |
| 408 | sh -c 'rm -rf deb_dist dist osm_rovim_azure.egg-info osm_rovim_azure*.tar.gz' |
| 409 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 410 | sh -c 'cd deb_dist/osm-rovim-azure*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 411 | |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 412 | |
| 413 | ####################################################################################### |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 414 | [testenv:dist_ro_vim_openstack] |
| 415 | deps = {[testenv]deps} |
| 416 | -r{toxinidir}/requirements-dist.txt |
| 417 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 418 | allowlist_externals = sh |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 419 | changedir = {toxinidir}/RO-VIM-openstack |
| 420 | commands = |
| 421 | sh -c 'rm -rf deb_dist dist osm_rovim_openstack.egg-info osm_rovim_openstack*.tar.gz' |
| 422 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 423 | sh -c 'cd deb_dist/osm-rovim-openstack*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 424 | |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 425 | |
| 426 | ####################################################################################### |
| 427 | [testenv:dist_ro_vim_openvim] |
| 428 | deps = {[testenv]deps} |
| 429 | -r{toxinidir}/requirements-dist.txt |
| 430 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 431 | allowlist_externals = sh |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 432 | changedir = {toxinidir}/RO-VIM-openvim |
| 433 | commands = |
| 434 | sh -c 'rm -rf deb_dist dist osm_rovim_openvim.egg-info osm_rovim_openvim*.tar.gz' |
| 435 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 436 | sh -c 'cd deb_dist/osm-rovim-openvim*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 437 | |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 438 | |
| 439 | ####################################################################################### |
| 440 | [testenv:dist_ro_vim_vmware] |
| 441 | deps = {[testenv]deps} |
| 442 | -r{toxinidir}/requirements-dist.txt |
| 443 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 444 | allowlist_externals = sh |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 445 | changedir = {toxinidir}/RO-VIM-vmware |
| 446 | commands = |
| 447 | sh -c 'rm -rf deb_dist dist osm_rovim_vmware.egg-info osm_rovim_vmware*.tar.gz' |
| 448 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 449 | sh -c 'cd deb_dist/osm-rovim-vmware*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| sousaedu | 89278b8 | 2021-11-19 01:01:32 +0000 | [diff] [blame] | 450 | |
| lloretgalleg | 6af6f6d | 2025-03-04 11:37:14 +0000 | [diff] [blame] | 451 | ####################################################################################### |
| 452 | [testenv:dist_ro_vim_vcenter] |
| 453 | deps = {[testenv]deps} |
| 454 | -r{toxinidir}/requirements-dist.txt |
| 455 | skip_install = true |
| 456 | allowlist_externals = sh |
| 457 | changedir = {toxinidir}/RO-VIM-vcenter |
| 458 | commands = |
| 459 | sh -c 'rm -rf deb_dist dist osm_rovim_vcenter.egg-info osm_rovim_vcenter*.tar.gz' |
| 460 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 461 | sh -c 'cd deb_dist/osm-rovim-vcenter*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| 462 | |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 463 | |
| 464 | ####################################################################################### |
| gallardo | 34aa3a9 | 2021-10-08 11:50:00 +0000 | [diff] [blame] | 465 | [testenv:dist_ro_vim_gcp] |
| 466 | deps = {[testenv]deps} |
| 467 | -r{toxinidir}/requirements-dist.txt |
| 468 | skip_install = true |
| garciadeblas | 1c89c08 | 2023-04-18 15:06:30 +0200 | [diff] [blame] | 469 | allowlist_externals = sh |
| gallardo | 34aa3a9 | 2021-10-08 11:50:00 +0000 | [diff] [blame] | 470 | changedir = {toxinidir}/RO-VIM-gcp |
| 471 | commands = |
| 472 | sh -c 'rm -rf deb_dist dist osm_rovim_gcp.egg-info osm_rovim_gcp*.tar.gz' |
| 473 | python3 setup.py --command-packages=stdeb.command sdist_dsc |
| 474 | sh -c 'cd deb_dist/osm-rovim-gcp*/ && dpkg-buildpackage -rfakeroot -uc -us' |
| gallardo | 34aa3a9 | 2021-10-08 11:50:00 +0000 | [diff] [blame] | 475 | |
| 476 | |
| 477 | ####################################################################################### |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 478 | [flake8] |
| 479 | ignore = |
| 480 | W291, |
| 481 | W293, |
| 482 | W503, |
| 483 | W605, |
| 484 | E123, |
| 485 | E125, |
| 486 | E203, |
| 487 | E226, |
| aticig | 7b521f7 | 2022-07-15 00:43:09 +0300 | [diff] [blame] | 488 | E241, |
| 489 | E501, |
| sousaedu | 96abfc2 | 2021-02-18 14:57:01 +0100 | [diff] [blame] | 490 | exclude = |
| 491 | .git, |
| 492 | __pycache__, |
| 493 | .tox, |
| 494 | max-line-length = 120 |
| 495 | show-source = True |
| 496 | builtins = _ |
| sousaedu | 049cbb1 | 2022-01-05 11:39:35 +0000 | [diff] [blame] | 497 | import-order-style = google |