Fix python code according to pylama errors

This commit is contained in:
Pieprzycki Piotr 2016-12-16 15:47:51 +01:00
parent 9b4d3aec64
commit 5afafa5522
4 changed files with 762 additions and 798 deletions

View File

@ -13,19 +13,8 @@ deploy:
tags: true
branch: master
script:
- cd test/unit
- nosetests -v TestIOSDriver:TestGetterIOSDriver.test_get_arp_table
- nosetests -v TestIOSDriver:TestGetterIOSDriver.test_get_bgp_neighbors
- nosetests -v TestIOSDriver:TestGetterIOSDriver.test_get_environment
- nosetests -v TestIOSDriver:TestGetterIOSDriver.test_get_facts
- nosetests -v TestIOSDriver:TestGetterIOSDriver.test_get_interfaces
- nosetests -v TestIOSDriver:TestGetterIOSDriver.test_get_interfaces_counters
- nosetests -v TestIOSDriver:TestGetterIOSDriver.test_get_interfaces_ip
- nosetests -v TestIOSDriver:TestGetterIOSDriver.test_get_lldp_neighbors
- nosetests -v TestIOSDriver:TestGetterIOSDriver.test_get_lldp_neighbors_detail
- nosetests -v TestIOSDriver:TestGetterIOSDriver.test_get_mac_address_table
- nosetests -v TestIOSDriver:TestGetterIOSDriver.test_get_ntp_stats
- nosetests -v TestIOSDriver:TestGetterIOSDriver.test_get_snmp_information
- nosetests -v TestIOSDriver:TestGetterIOSDriver.test_ios_only_bgp_time_conversion
- nosetests -v TestIOSDriver:TestGetterIOSDriver.test_ping
- cd ../..
- py.test --cov-report= --cov=napalm_vyos test/
- pylama .
after_success:
- coveralls
- if [ $TRAVIS_TAG ]; then curl -X POST https://readthedocs.org/build/napalm; fi

File diff suppressed because it is too large Load Diff

View File

@ -5,7 +5,7 @@ ignore = D203,C901
[pylama:pep8]
max_line_length = 100
[pytest]
[tools:pytest]
addopts = --cov=./ -vs
json_report = report.json
jsonapi = true

View File

@ -28,9 +28,9 @@ class TestConfigVyOSDriver(unittest.TestCase, TestConfigNetworkDriver):
cls.vendor = 'vyos'
cls.port = '2200'
optional_args = {'port': '2200' }
optional_args = {'port': '2200'}
cls.device = vyos.VyOSDriver(hostname, username, password,
timeout=60, optional_args=optional_args)
timeout=60, optional_args=optional_args)
cls.device.open()
cls.device.load_replace_candidate(filename='%s/initial.conf' % cls.vendor)