diff --git a/test/unit/mocked_data/test_get_config_filtered/SG500-28-K9/expected_result.json b/test/unit/mocked_data/test_get_config_filtered/SG500-28-K9/expected_result.json new file mode 100644 index 0000000..4b0f49d --- /dev/null +++ b/test/unit/mocked_data/test_get_config_filtered/SG500-28-K9/expected_result.json @@ -0,0 +1,5 @@ +{ + "startup": "", + "running": "", + "candidate": "" +} diff --git a/test/unit/mocked_data/test_get_config_filtered/SG500-28-K9/show_running_config.txt b/test/unit/mocked_data/test_get_config_filtered/SG500-28-K9/show_running_config.txt new file mode 100644 index 0000000..a2c1765 --- /dev/null +++ b/test/unit/mocked_data/test_get_config_filtered/SG500-28-K9/show_running_config.txt @@ -0,0 +1,154 @@ +config-file-header +switch1 +v1.3.5.58 / R750_NIK_1_35_647_358 +CLI v1.0 +set system mode switch queues-mode 4 + +file SSD indicator encrypted +@ +ssd-control-start +ssd config +ssd file passphrase control unrestricted +no ssd file integrity control +ssd-control-end cb0a3fdb1f3a1af4e4430033719968c0 +! +vlan database +vlan 10,20,30 +exit +voice vlan oui-table add 0001e3 Siemens_AG_phone________ +voice vlan oui-table add 00036b Cisco_phone_____________ +voice vlan oui-table add 00096e Avaya___________________ +voice vlan oui-table add 000fe2 H3C_Aolynk______________ +voice vlan oui-table add 0060b9 Philips_and_NEC_AG_phone +voice vlan oui-table add 00d01e Pingtel_phone___________ +voice vlan oui-table add 00e075 Polycom/Veritel_phone___ +voice vlan oui-table add 00e0bb 3Com_phone______________ +hostname switch1 +username cisco password encrypted dddd5d7b474d2c78ebbb833789c4bfd721edf4bf privilege 15 +ip ssh server +ip ssh password-auth +snmp-server server +snmp-server community findit ro view Default +! +interface vlan 10 + ip address 10.0.3.5 255.0.0.0 +! +interface gigabitethernet1/1/1 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/2 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/3 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/4 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/5 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/6 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/7 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/8 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/9 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/10 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/11 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/12 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/13 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/14 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/15 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/16 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/17 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/18 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/19 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/20 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/21 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/22 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/23 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/24 + switchport mode access + switchport access vlan 30 +! +interface gigabitethernet1/1/25 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/26 + spanning-tree disable + spanning-tree link-type point-to-point + switchport trunk allowed vlan add 10,30 + switchport trunk native vlan 20 + macro description switch + !next command is internal. + macro auto smartport dynamic_type switch +! +interface gigabitethernet1/1/27 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/28 + spanning-tree disable + switchport mode access + switchport access vlan 20 +! +exit diff --git a/test/unit/mocked_data/test_get_config_filtered/SG500-28-K9/show_startup_config.txt b/test/unit/mocked_data/test_get_config_filtered/SG500-28-K9/show_startup_config.txt new file mode 100644 index 0000000..a2c1765 --- /dev/null +++ b/test/unit/mocked_data/test_get_config_filtered/SG500-28-K9/show_startup_config.txt @@ -0,0 +1,154 @@ +config-file-header +switch1 +v1.3.5.58 / R750_NIK_1_35_647_358 +CLI v1.0 +set system mode switch queues-mode 4 + +file SSD indicator encrypted +@ +ssd-control-start +ssd config +ssd file passphrase control unrestricted +no ssd file integrity control +ssd-control-end cb0a3fdb1f3a1af4e4430033719968c0 +! +vlan database +vlan 10,20,30 +exit +voice vlan oui-table add 0001e3 Siemens_AG_phone________ +voice vlan oui-table add 00036b Cisco_phone_____________ +voice vlan oui-table add 00096e Avaya___________________ +voice vlan oui-table add 000fe2 H3C_Aolynk______________ +voice vlan oui-table add 0060b9 Philips_and_NEC_AG_phone +voice vlan oui-table add 00d01e Pingtel_phone___________ +voice vlan oui-table add 00e075 Polycom/Veritel_phone___ +voice vlan oui-table add 00e0bb 3Com_phone______________ +hostname switch1 +username cisco password encrypted dddd5d7b474d2c78ebbb833789c4bfd721edf4bf privilege 15 +ip ssh server +ip ssh password-auth +snmp-server server +snmp-server community findit ro view Default +! +interface vlan 10 + ip address 10.0.3.5 255.0.0.0 +! +interface gigabitethernet1/1/1 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/2 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/3 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/4 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/5 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/6 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/7 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/8 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/9 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/10 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/11 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/12 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/13 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/14 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/15 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/16 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/17 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/18 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/19 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/20 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/21 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/22 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/23 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/24 + switchport mode access + switchport access vlan 30 +! +interface gigabitethernet1/1/25 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/26 + spanning-tree disable + spanning-tree link-type point-to-point + switchport trunk allowed vlan add 10,30 + switchport trunk native vlan 20 + macro description switch + !next command is internal. + macro auto smartport dynamic_type switch +! +interface gigabitethernet1/1/27 + switchport mode access + switchport access vlan 20 +! +interface gigabitethernet1/1/28 + spanning-tree disable + switchport mode access + switchport access vlan 20 +! +exit