tests: Added testing for Arista EOS BGP (#7984)

* tests: Added testing fro Arista EOS BGP

* fixing tests

* small updates

* last one

* more updates

* Account for no space after = in snmp data
always load_os() when a new device is freshly loaded by device_by_id_cache()

* don't be fatal in load_os()

* Update json to correct data
This commit is contained in:
Neil Lathwood
2017-12-30 10:31:06 +00:00
committed by GitHub
parent b841909a42
commit 7d0ad5c4ef
4 changed files with 225 additions and 5 deletions

View File

@@ -241,9 +241,10 @@ class ModuleTestHelper
continue;
}
if (str_contains($line, ' = ')) {
list($oid, $raw_data) = explode(' = ', $line, 2);
if (str_contains($line, ' =')) {
list($oid, $raw_data) = explode(' =', $line, 2);
$oid = ltrim($oid, '.');
$raw_data = trim($raw_data);
if (empty($raw_data)) {
$result[] = "$oid|4|"; // empty data, we don't know type, put string