From 3d156b2ca43324401c34c6da3f806f6da993cc19 Mon Sep 17 00:00:00 2001 From: danischm Date: Sun, 31 Mar 2024 09:07:04 +0200 Subject: [PATCH] Update test versions --- docs/index.md | 2 +- docs/resources/bgp_ipv4_unicast_vrf_neighbor.md | 1 - docs/resources/evpn_instance.md | 2 -- docs/resources/snmp_server.md | 1 - .../resource.tf | 1 - .../resources/iosxe_evpn_instance/resource.tf | 2 -- examples/resources/iosxe_snmp_server/resource.tf | 1 - gen/definitions/aaa_accounting.yaml | 2 +- gen/definitions/bfd_template_multi_hop.yaml | 16 ++++++++-------- gen/definitions/bfd_template_single_hop.yaml | 12 ++++++------ .../bgp_ipv4_unicast_vrf_neighbor.yaml | 1 + gen/definitions/errdisable.yaml | 4 ++-- gen/definitions/evpn_instance.yaml | 2 ++ gen/definitions/interface_port_channel.yaml | 14 +++++++------- .../interface_port_channel_subinterface.yaml | 14 +++++++------- gen/definitions/interface_tunnel.yaml | 14 +++++++------- gen/definitions/route_map.yaml | 4 ++-- gen/definitions/snmp_server.yaml | 5 +++-- .../data_source_iosxe_aaa_accounting_test.go | 4 ++-- ...a_source_iosxe_bfd_template_multi_hop_test.go | 12 ++++++------ ..._source_iosxe_bfd_template_single_hop_test.go | 12 ++++++------ ...e_iosxe_bgp_ipv4_unicast_vrf_neighbor_test.go | 9 +++++++-- .../data_source_iosxe_errdisable_test.go | 8 ++++---- .../data_source_iosxe_evpn_instance_test.go | 16 ++++++++++++---- ...e_interface_port_channel_subinterface_test.go | 12 ++++++------ ...a_source_iosxe_interface_port_channel_test.go | 12 ++++++------ .../data_source_iosxe_interface_tunnel_test.go | 12 ++++++------ .../provider/data_source_iosxe_route_map_test.go | 8 ++++---- .../data_source_iosxe_snmp_server_test.go | 16 ++++++++++------ .../resource_iosxe_aaa_accounting_test.go | 4 ++-- ...resource_iosxe_bfd_template_multi_hop_test.go | 12 ++++++------ ...esource_iosxe_bfd_template_single_hop_test.go | 12 ++++++------ ...e_iosxe_bgp_ipv4_unicast_vrf_neighbor_test.go | 9 +++++++-- internal/provider/resource_iosxe_cli_test.go | 4 ++-- .../provider/resource_iosxe_errdisable_test.go | 8 ++++---- .../resource_iosxe_evpn_instance_test.go | 16 ++++++++++++---- ...e_interface_port_channel_subinterface_test.go | 12 ++++++------ ...resource_iosxe_interface_port_channel_test.go | 12 ++++++------ .../resource_iosxe_interface_tunnel_test.go | 12 ++++++------ .../provider/resource_iosxe_route_map_test.go | 8 ++++---- .../provider/resource_iosxe_snmp_server_test.go | 16 ++++++++++------ templates/index.md.tmpl | 2 +- 42 files changed, 188 insertions(+), 158 deletions(-) diff --git a/docs/index.md b/docs/index.md index e7597967..1787b7c5 100644 --- a/docs/index.md +++ b/docs/index.md @@ -27,7 +27,7 @@ All resources and data sources have been tested with the following releases. | -------------- | ------- | | Catalyst 8000v | 17.6.5 | | Catalyst 8000v | 17.9.4 | -| Catalyst 9000v | 17.10.1 | +| Catalyst 9000v | 17.13.1 | ## Example Usage diff --git a/docs/resources/bgp_ipv4_unicast_vrf_neighbor.md b/docs/resources/bgp_ipv4_unicast_vrf_neighbor.md index f4db279f..023aeb92 100644 --- a/docs/resources/bgp_ipv4_unicast_vrf_neighbor.md +++ b/docs/resources/bgp_ipv4_unicast_vrf_neighbor.md @@ -20,7 +20,6 @@ resource "iosxe_bgp_ipv4_unicast_vrf_neighbor" "example" { remote_as = "65000" description = "BGP Neighbor Description" shutdown = false - cluster_id = "2.2.2.2" log_neighbor_changes_disable = true password_type = 1 password = "LINE" diff --git a/docs/resources/evpn_instance.md b/docs/resources/evpn_instance.md index c275d698..0db54718 100644 --- a/docs/resources/evpn_instance.md +++ b/docs/resources/evpn_instance.md @@ -22,8 +22,6 @@ resource "iosxe_evpn_instance" "example" { vlan_based_encapsulation = "vxlan" vlan_based_auto_route_target = false vlan_based_rd = "10:10" - vlan_based_route_target = "10:10" - vlan_based_route_target_both = "10:10" vlan_based_route_target_import = "10:10" vlan_based_route_target_export = "10:10" vlan_based_ip_local_learning_disable = false diff --git a/docs/resources/snmp_server.md b/docs/resources/snmp_server.md index 2fe837c2..cd9e0f56 100644 --- a/docs/resources/snmp_server.md +++ b/docs/resources/snmp_server.md @@ -57,7 +57,6 @@ resource "iosxe_snmp_server" "example" { enable_traps_vlancreate = true enable_traps_vlandelete = true enable_traps_port_security = true - enable_traps_license = true enable_traps_smart_license = true enable_traps_cpu_threshold = true enable_traps_memory_bufferpeak = true diff --git a/examples/resources/iosxe_bgp_ipv4_unicast_vrf_neighbor/resource.tf b/examples/resources/iosxe_bgp_ipv4_unicast_vrf_neighbor/resource.tf index 90f79a61..a8f4eb81 100644 --- a/examples/resources/iosxe_bgp_ipv4_unicast_vrf_neighbor/resource.tf +++ b/examples/resources/iosxe_bgp_ipv4_unicast_vrf_neighbor/resource.tf @@ -5,7 +5,6 @@ resource "iosxe_bgp_ipv4_unicast_vrf_neighbor" "example" { remote_as = "65000" description = "BGP Neighbor Description" shutdown = false - cluster_id = "2.2.2.2" log_neighbor_changes_disable = true password_type = 1 password = "LINE" diff --git a/examples/resources/iosxe_evpn_instance/resource.tf b/examples/resources/iosxe_evpn_instance/resource.tf index 641d0e1c..2877c78d 100644 --- a/examples/resources/iosxe_evpn_instance/resource.tf +++ b/examples/resources/iosxe_evpn_instance/resource.tf @@ -7,8 +7,6 @@ resource "iosxe_evpn_instance" "example" { vlan_based_encapsulation = "vxlan" vlan_based_auto_route_target = false vlan_based_rd = "10:10" - vlan_based_route_target = "10:10" - vlan_based_route_target_both = "10:10" vlan_based_route_target_import = "10:10" vlan_based_route_target_export = "10:10" vlan_based_ip_local_learning_disable = false diff --git a/examples/resources/iosxe_snmp_server/resource.tf b/examples/resources/iosxe_snmp_server/resource.tf index f7b3317f..9a55fe43 100644 --- a/examples/resources/iosxe_snmp_server/resource.tf +++ b/examples/resources/iosxe_snmp_server/resource.tf @@ -42,7 +42,6 @@ resource "iosxe_snmp_server" "example" { enable_traps_vlancreate = true enable_traps_vlandelete = true enable_traps_port_security = true - enable_traps_license = true enable_traps_smart_license = true enable_traps_cpu_threshold = true enable_traps_memory_bufferpeak = true diff --git a/gen/definitions/aaa_accounting.yaml b/gen/definitions/aaa_accounting.yaml index ad3d3a1c..2a35d5b7 100644 --- a/gen/definitions/aaa_accounting.yaml +++ b/gen/definitions/aaa_accounting.yaml @@ -10,7 +10,7 @@ attributes: - yang_name: identity/accounting-list tf_name: identities type: List - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] attributes: - yang_name: name id: true diff --git a/gen/definitions/bfd_template_multi_hop.yaml b/gen/definitions/bfd_template_multi_hop.yaml index ae80a0a7..15c42d1d 100644 --- a/gen/definitions/bfd_template_multi_hop.yaml +++ b/gen/definitions/bfd_template_multi_hop.yaml @@ -13,28 +13,28 @@ attributes: tf_name: interval_milliseconds_both example: 8234 exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: interval-multihop-v2/units/unit-mill/mill-unit/interval-types/tx-rx/min-tx xpath: interval-multihop-v2/mill-unit/min-tx tf_name: interval_milliseconds_min_tx example: 4500 - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: interval-multihop-v2/units/unit-mill/mill-unit/interval-types/tx-rx/min-rx xpath: interval-multihop-v2/mill-unit/min-rx tf_name: interval_milliseconds_min_rx example: 5500 - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: interval-multihop-v2/units/unit-mill/mill-unit/multiplier xpath: interval-multihop-v2/mill-unit/multiplier tf_name: interval_milliseconds_multiplier example: 40 - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: interval-multihop-v2/units/unit-ms/ms-unit/microseconds xpath: interval-multihop-v2/microseconds tf_name: interval_microseconds example: true exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: interval-multihop-v2/units/unit-ms/ms-unit/interval-types/both/both xpath: interval-multihop-v2/both tf_name: interval_microseconds_both @@ -45,19 +45,19 @@ attributes: tf_name: interval_microseconds_min_tx example: 4500 exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: interval-multihop-v2/units/unit-ms/ms-unit/interval-types/tx-rx/min-rx xpath: interval-multihop-v2/min-rx tf_name: interval_microseconds_min_rx example: 5500 exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: interval-multihop-v2/units/unit-ms/ms-unit/multiplier xpath: interval-multihop-v2/multiplier tf_name: interval_microseconds_multiplier example: 40 exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: authentication/auth-type/md5/md5/keychain xpath: authentication/md5/keychain tf_name: authentication_md5_keychain diff --git a/gen/definitions/bfd_template_single_hop.yaml b/gen/definitions/bfd_template_single_hop.yaml index f7a5098c..4b2a914c 100644 --- a/gen/definitions/bfd_template_single_hop.yaml +++ b/gen/definitions/bfd_template_single_hop.yaml @@ -29,35 +29,35 @@ attributes: xpath: interval-singlehop-v2/mill-unit/min-tx tf_name: interval_milliseconds_min_tx example: 200 - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: interval-singlehop-v2/units/unit-mill/mill-unit/interval-types/tx-rx/min-rx xpath: interval-singlehop-v2/mill-unit/min-rx tf_name: interval_milliseconds_min_rx example: 200 - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: interval-singlehop-v2/units/unit-mill/mill-unit/interval-types/both/both xpath: interval-singlehop-v2/mill-unit/both tf_name: interval_milliseconds_both example: 5 exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: interval-singlehop-v2/units/unit-mill/mill-unit/multiplier xpath: interval-singlehop-v2/mill-unit/multiplier tf_name: interval_milliseconds_multiplier example: 4 - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: interval-singlehop-v2/units/unit-ms/ms-unit/interval-types/tx-rx/min-rx xpath: interval-singlehop-v2/ms-unit/min-rx tf_name: interval_microseconds_min_rx example: 200 exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: interval-singlehop-v2/units/unit-ms/ms-unit/interval-types/tx-rx/min-tx xpath: interval-singlehop-v2/ms-unit/min-tx tf_name: interval_microseconds_min_tx example: 200 exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: echo example: true - yang_name: dampening/half-time diff --git a/gen/definitions/bgp_ipv4_unicast_vrf_neighbor.yaml b/gen/definitions/bgp_ipv4_unicast_vrf_neighbor.yaml index a6fc3a86..0c129f6d 100644 --- a/gen/definitions/bgp_ipv4_unicast_vrf_neighbor.yaml +++ b/gen/definitions/bgp_ipv4_unicast_vrf_neighbor.yaml @@ -25,6 +25,7 @@ attributes: example: false - yang_name: cluster-id example: 2.2.2.2 + test_tags: [IOSXE176, IOSXE179] - yang_name: log-neighbor-changes/disable example: true - yang_name: password/enctype diff --git a/gen/definitions/errdisable.yaml b/gen/definitions/errdisable.yaml index d86f7c74..e5b88c3a 100644 --- a/gen/definitions/errdisable.yaml +++ b/gen/definitions/errdisable.yaml @@ -47,7 +47,7 @@ attributes: exclude_test: true - yang_name: detect/cause/loopdetect example: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: flap-setting/cause/dtp-flap/max-flaps example: 80 delete_parent: true @@ -135,4 +135,4 @@ attributes: exclude_test: true - yang_name: recovery/cause/loopdetect example: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] diff --git a/gen/definitions/evpn_instance.yaml b/gen/definitions/evpn_instance.yaml index 3d251ae1..65587db2 100644 --- a/gen/definitions/evpn_instance.yaml +++ b/gen/definitions/evpn_instance.yaml @@ -40,10 +40,12 @@ attributes: xpath: vlan-based/route-target/rt-value tf_name: vlan_based_route_target example: 10:10 + test_tags: [IOSXE176, IOSXE179] - yang_name: evpn-service-type/vlan-based/vlan-based/route-target/both/rt-value xpath: vlan-based/route-target/both/rt-value tf_name: vlan_based_route_target_both example: 10:10 + test_tags: [IOSXE176, IOSXE179] - yang_name: evpn-service-type/vlan-based/vlan-based/route-target/import/rt-value xpath: vlan-based/route-target/import/rt-value tf_name: vlan_based_route_target_import diff --git a/gen/definitions/interface_port_channel.yaml b/gen/definitions/interface_port_channel.yaml index db015fdc..475331bc 100644 --- a/gen/definitions/interface_port_channel.yaml +++ b/gen/definitions/interface_port_channel.yaml @@ -115,38 +115,38 @@ attributes: example: VRF1 - yang_name: bfd/Cisco-IOS-XE-bfd:template example: bfd_template1 - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:enable example: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:local-address example: 1.2.3.4 - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:interval-interface/msecs tf_name: bfd_interval optional: true example: 1000 delete_parent: true exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:interval-interface/min_rx tf_name: bfd_interval_min_rx optional: true example: 1000 delete_parent: true exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:interval-interface/multiplier tf_name: bfd_interval_multiplier optional: true example: 3 delete_parent: true exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:echo example: true exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: ipv6/enable example: true - yang_name: ipv6/mtu diff --git a/gen/definitions/interface_port_channel_subinterface.yaml b/gen/definitions/interface_port_channel_subinterface.yaml index 0e3a95a6..d5f1b3d9 100644 --- a/gen/definitions/interface_port_channel_subinterface.yaml +++ b/gen/definitions/interface_port_channel_subinterface.yaml @@ -107,38 +107,38 @@ attributes: example: VRF1 - yang_name: bfd/Cisco-IOS-XE-bfd:template example: bfd_template1 - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:enable example: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:local-address example: 1.2.3.4 - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:interval-interface/msecs tf_name: bfd_interval optional: true example: 50 delete_parent: true exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:interval-interface/min_rx tf_name: bfd_interval_min_rx optional: true example: 50 delete_parent: true exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:interval-interface/multiplier tf_name: bfd_interval_multiplier optional: true example: 3 delete_parent: true exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:echo example: true exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: ipv6/enable example: true - yang_name: ipv6/mtu diff --git a/gen/definitions/interface_tunnel.yaml b/gen/definitions/interface_tunnel.yaml index 3c7b62c2..a203e005 100644 --- a/gen/definitions/interface_tunnel.yaml +++ b/gen/definitions/interface_tunnel.yaml @@ -123,38 +123,38 @@ attributes: test_tags: [C8000V] - yang_name: bfd/Cisco-IOS-XE-bfd:template example: bfd_template1 - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:enable example: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:local-address example: 1.2.3.4 - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:interval-interface/msecs tf_name: bfd_interval optional: true example: 50 delete_parent: true exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:interval-interface/min_rx tf_name: bfd_interval_min_rx optional: true example: 50 delete_parent: true exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:interval-interface/multiplier tf_name: bfd_interval_multiplier optional: true example: 3 delete_parent: true exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: bfd/Cisco-IOS-XE-bfd:echo example: true exclude_test: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] test_prerequisites: - path: Cisco-IOS-XE-native:native/vrf/definition=VRF1 diff --git a/gen/definitions/route_map.yaml b/gen/definitions/route_map.yaml index 5b96a41f..10f2f286 100644 --- a/gen/definitions/route_map.yaml +++ b/gen/definitions/route_map.yaml @@ -97,11 +97,11 @@ attributes: - yang_name: match/community/name tf_name: match_community_lists_legacy example: COMM1 - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: match/extcommunity/name tf_name: match_extcommunity_lists_legacy example: EXTCOMM1 - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: match/local-preference/values tf_name: match_local_preferences_legacy example: 100 diff --git a/gen/definitions/snmp_server.yaml b/gen/definitions/snmp_server.yaml index a56caa71..8c6eda0e 100644 --- a/gen/definitions/snmp_server.yaml +++ b/gen/definitions/snmp_server.yaml @@ -64,7 +64,7 @@ attributes: - yang_name: Cisco-IOS-XE-snmp:enable/enable-choice/traps/entity-perf/throughput-notif tf_name: enable_traps_entity_perf_throughput_notif example: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: Cisco-IOS-XE-snmp:enable/enable-choice/traps/call-home/message-send-fail tf_name: enable_traps_call_home_message_send_fail example: true @@ -129,6 +129,7 @@ attributes: - yang_name: Cisco-IOS-XE-snmp:enable/enable-choice/traps/license tf_name: enable_traps_license example: true + test_tags: [IOSXE176, IOSXE179] - yang_name: Cisco-IOS-XE-snmp:enable/enable-choice/traps/smart-licenseing/smart-license tf_name: enable_traps_smart_license example: true @@ -162,7 +163,7 @@ attributes: - yang_name: Cisco-IOS-XE-snmp:enable/enable-choice/traps/flash/lowspace tf_name: enable_traps_flash_lowspace example: true - test_tags: [IOSXE179, IOSXE1710] + test_tags: [IOSXE179, IOSXE1713] - yang_name: Cisco-IOS-XE-snmp:enable/enable-choice/traps/energywise tf_name: enable_traps_energywise example: true diff --git a/internal/provider/data_source_iosxe_aaa_accounting_test.go b/internal/provider/data_source_iosxe_aaa_accounting_test.go index 8c2c06ca..498208c6 100644 --- a/internal/provider/data_source_iosxe_aaa_accounting_test.go +++ b/internal/provider/data_source_iosxe_aaa_accounting_test.go @@ -29,7 +29,7 @@ import ( func TestAccDataSourceIosxeAAAAccounting(t *testing.T) { var checks []resource.TestCheckFunc checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_aaa_accounting.test", "update_newinfo_periodic", "2880")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_aaa_accounting.test", "identities.0.name", "test")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_aaa_accounting.test", "identities.0.start_stop_broadcast", "false")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_aaa_accounting.test", "identities.0.start_stop_group_broadcast", "false")) @@ -65,7 +65,7 @@ func testAccDataSourceIosxeAAAAccountingConfig() string { config := `resource "iosxe_aaa_accounting" "test" {` + "\n" config += ` delete_mode = "attributes"` + "\n" config += ` update_newinfo_periodic = 2880` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` identities = [{` + "\n" config += ` name = "test"` + "\n" config += ` start_stop_broadcast = false` + "\n" diff --git a/internal/provider/data_source_iosxe_bfd_template_multi_hop_test.go b/internal/provider/data_source_iosxe_bfd_template_multi_hop_test.go index c5350bd0..8ca3a136 100644 --- a/internal/provider/data_source_iosxe_bfd_template_multi_hop_test.go +++ b/internal/provider/data_source_iosxe_bfd_template_multi_hop_test.go @@ -29,13 +29,13 @@ import ( func TestAccDataSourceIosxeBFDTemplateMultiHop(t *testing.T) { var checks []resource.TestCheckFunc checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bfd_template_multi_hop.test", "echo", "true")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bfd_template_multi_hop.test", "interval_milliseconds_min_tx", "4500")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bfd_template_multi_hop.test", "interval_milliseconds_min_rx", "5500")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bfd_template_multi_hop.test", "interval_milliseconds_multiplier", "40")) } checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bfd_template_multi_hop.test", "authentication_md5_keychain", "KEYNAME")) @@ -59,13 +59,13 @@ func testAccDataSourceIosxeBFDTemplateMultiHopConfig() string { config := `resource "iosxe_bfd_template_multi_hop" "test" {` + "\n" config += ` name = "T11"` + "\n" config += ` echo = true` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` interval_milliseconds_min_tx = 4500` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` interval_milliseconds_min_rx = 5500` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` interval_milliseconds_multiplier = 40` + "\n" } config += ` authentication_md5_keychain = "KEYNAME"` + "\n" diff --git a/internal/provider/data_source_iosxe_bfd_template_single_hop_test.go b/internal/provider/data_source_iosxe_bfd_template_single_hop_test.go index 7e30a40b..207833d6 100644 --- a/internal/provider/data_source_iosxe_bfd_template_single_hop_test.go +++ b/internal/provider/data_source_iosxe_bfd_template_single_hop_test.go @@ -29,13 +29,13 @@ import ( func TestAccDataSourceIosxeBFDTemplateSingleHop(t *testing.T) { var checks []resource.TestCheckFunc checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bfd_template_single_hop.test", "authentication_md5_keychain", "KEYC1")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bfd_template_single_hop.test", "interval_milliseconds_min_tx", "200")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bfd_template_single_hop.test", "interval_milliseconds_min_rx", "200")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bfd_template_single_hop.test", "interval_milliseconds_multiplier", "4")) } checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bfd_template_single_hop.test", "echo", "true")) @@ -59,13 +59,13 @@ func testAccDataSourceIosxeBFDTemplateSingleHopConfig() string { config := `resource "iosxe_bfd_template_single_hop" "test" {` + "\n" config += ` name = "SH-TEMPLATE-1"` + "\n" config += ` authentication_md5_keychain = "KEYC1"` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` interval_milliseconds_min_tx = 200` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` interval_milliseconds_min_rx = 200` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` interval_milliseconds_multiplier = 4` + "\n" } config += ` echo = true` + "\n" diff --git a/internal/provider/data_source_iosxe_bgp_ipv4_unicast_vrf_neighbor_test.go b/internal/provider/data_source_iosxe_bgp_ipv4_unicast_vrf_neighbor_test.go index 2ce3f344..08288106 100644 --- a/internal/provider/data_source_iosxe_bgp_ipv4_unicast_vrf_neighbor_test.go +++ b/internal/provider/data_source_iosxe_bgp_ipv4_unicast_vrf_neighbor_test.go @@ -20,6 +20,7 @@ package provider import ( + "os" "testing" "github.com/hashicorp/terraform-plugin-testing/helper/resource" @@ -30,7 +31,9 @@ func TestAccDataSourceIosxeBGPIPv4UnicastVRFNeighbor(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bgp_ipv4_unicast_vrf_neighbor.test", "remote_as", "65000")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bgp_ipv4_unicast_vrf_neighbor.test", "description", "BGP Neighbor Description")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bgp_ipv4_unicast_vrf_neighbor.test", "shutdown", "false")) - checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bgp_ipv4_unicast_vrf_neighbor.test", "cluster_id", "2.2.2.2")) + if os.Getenv("IOSXE176") != "" || os.Getenv("IOSXE179") != "" { + checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bgp_ipv4_unicast_vrf_neighbor.test", "cluster_id", "2.2.2.2")) + } checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bgp_ipv4_unicast_vrf_neighbor.test", "log_neighbor_changes_disable", "true")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bgp_ipv4_unicast_vrf_neighbor.test", "password_type", "1")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_bgp_ipv4_unicast_vrf_neighbor.test", "password", "LINE")) @@ -124,7 +127,9 @@ func testAccDataSourceIosxeBGPIPv4UnicastVRFNeighborConfig() string { config += ` remote_as = "65000"` + "\n" config += ` description = "BGP Neighbor Description"` + "\n" config += ` shutdown = false` + "\n" - config += ` cluster_id = "2.2.2.2"` + "\n" + if os.Getenv("IOSXE176") != "" || os.Getenv("IOSXE179") != "" { + config += ` cluster_id = "2.2.2.2"` + "\n" + } config += ` log_neighbor_changes_disable = true` + "\n" config += ` password_type = 1` + "\n" config += ` password = "LINE"` + "\n" diff --git a/internal/provider/data_source_iosxe_errdisable_test.go b/internal/provider/data_source_iosxe_errdisable_test.go index 8fe069cf..1fdc42f9 100644 --- a/internal/provider/data_source_iosxe_errdisable_test.go +++ b/internal/provider/data_source_iosxe_errdisable_test.go @@ -40,7 +40,7 @@ func TestAccDataSourceIosxeErrdisable(t *testing.T) { if os.Getenv("C9000V") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_errdisable.test", "detect_cause_security_violation_shutdown_vlan", "true")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_errdisable.test", "detect_cause_loopdetect", "true")) } checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_errdisable.test", "flap_setting_cause_dtp_flap_max_flaps", "80")) @@ -90,7 +90,7 @@ func TestAccDataSourceIosxeErrdisable(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_errdisable.test", "recovery_cause_storm_control", "true")) } checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_errdisable.test", "recovery_cause_udld", "true")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_errdisable.test", "recovery_cause_loopdetect", "true")) } resource.Test(t, resource.TestCase{ @@ -120,7 +120,7 @@ func testAccDataSourceIosxeErrdisableConfig() string { if os.Getenv("C9000V") != "" { config += ` detect_cause_security_violation_shutdown_vlan = true` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` detect_cause_loopdetect = true` + "\n" } config += ` flap_setting_cause_dtp_flap_max_flaps = 80` + "\n" @@ -170,7 +170,7 @@ func testAccDataSourceIosxeErrdisableConfig() string { config += ` recovery_cause_storm_control = true` + "\n" } config += ` recovery_cause_udld = true` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` recovery_cause_loopdetect = true` + "\n" } config += `}` + "\n" diff --git a/internal/provider/data_source_iosxe_evpn_instance_test.go b/internal/provider/data_source_iosxe_evpn_instance_test.go index 15818e65..2ba4260e 100644 --- a/internal/provider/data_source_iosxe_evpn_instance_test.go +++ b/internal/provider/data_source_iosxe_evpn_instance_test.go @@ -38,8 +38,12 @@ func TestAccDataSourceIosxeEVPNInstance(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_evpn_instance.test", "vlan_based_encapsulation", "vxlan")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_evpn_instance.test", "vlan_based_auto_route_target", "false")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_evpn_instance.test", "vlan_based_rd", "10:10")) - checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_evpn_instance.test", "vlan_based_route_target", "10:10")) - checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_evpn_instance.test", "vlan_based_route_target_both", "10:10")) + if os.Getenv("IOSXE176") != "" || os.Getenv("IOSXE179") != "" { + checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_evpn_instance.test", "vlan_based_route_target", "10:10")) + } + if os.Getenv("IOSXE176") != "" || os.Getenv("IOSXE179") != "" { + checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_evpn_instance.test", "vlan_based_route_target_both", "10:10")) + } checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_evpn_instance.test", "vlan_based_route_target_import", "10:10")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_evpn_instance.test", "vlan_based_route_target_export", "10:10")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_evpn_instance.test", "vlan_based_ip_local_learning_disable", "false")) @@ -68,8 +72,12 @@ func testAccDataSourceIosxeEVPNInstanceConfig() string { config += ` vlan_based_encapsulation = "vxlan"` + "\n" config += ` vlan_based_auto_route_target = false` + "\n" config += ` vlan_based_rd = "10:10"` + "\n" - config += ` vlan_based_route_target = "10:10"` + "\n" - config += ` vlan_based_route_target_both = "10:10"` + "\n" + if os.Getenv("IOSXE176") != "" || os.Getenv("IOSXE179") != "" { + config += ` vlan_based_route_target = "10:10"` + "\n" + } + if os.Getenv("IOSXE176") != "" || os.Getenv("IOSXE179") != "" { + config += ` vlan_based_route_target_both = "10:10"` + "\n" + } config += ` vlan_based_route_target_import = "10:10"` + "\n" config += ` vlan_based_route_target_export = "10:10"` + "\n" config += ` vlan_based_ip_local_learning_disable = false` + "\n" diff --git a/internal/provider/data_source_iosxe_interface_port_channel_subinterface_test.go b/internal/provider/data_source_iosxe_interface_port_channel_subinterface_test.go index fcb150b5..3a52814d 100644 --- a/internal/provider/data_source_iosxe_interface_port_channel_subinterface_test.go +++ b/internal/provider/data_source_iosxe_interface_port_channel_subinterface_test.go @@ -46,13 +46,13 @@ func TestAccDataSourceIosxeInterfacePortChannelSubinterface(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_port_channel_subinterface.test", "ip_access_group_out_enable", "true")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_port_channel_subinterface.test", "helper_addresses.0.address", "10.10.10.10")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_port_channel_subinterface.test", "helper_addresses.0.global", "false")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_port_channel_subinterface.test", "bfd_template", "bfd_template1")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_port_channel_subinterface.test", "bfd_enable", "true")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_port_channel_subinterface.test", "bfd_local_address", "1.2.3.4")) } checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_port_channel_subinterface.test", "ipv6_enable", "true")) @@ -130,13 +130,13 @@ func testAccDataSourceIosxeInterfacePortChannelSubinterfaceConfig() string { config += ` address = "10.10.10.10"` + "\n" config += ` global = false` + "\n" config += ` }]` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_template = "bfd_template1"` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_enable = true` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_local_address = "1.2.3.4"` + "\n" } config += ` ipv6_enable = true` + "\n" diff --git a/internal/provider/data_source_iosxe_interface_port_channel_test.go b/internal/provider/data_source_iosxe_interface_port_channel_test.go index 72ec51ad..706b1908 100644 --- a/internal/provider/data_source_iosxe_interface_port_channel_test.go +++ b/internal/provider/data_source_iosxe_interface_port_channel_test.go @@ -52,13 +52,13 @@ func TestAccDataSourceIosxeInterfacePortChannel(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_port_channel.test", "ip_dhcp_relay_source_interface", "Loopback100")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_port_channel.test", "helper_addresses.0.address", "10.10.10.10")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_port_channel.test", "helper_addresses.0.global", "false")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_port_channel.test", "bfd_template", "bfd_template1")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_port_channel.test", "bfd_enable", "true")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_port_channel.test", "bfd_local_address", "1.2.3.4")) } checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_port_channel.test", "ipv6_enable", "true")) @@ -130,13 +130,13 @@ func testAccDataSourceIosxeInterfacePortChannelConfig() string { config += ` address = "10.10.10.10"` + "\n" config += ` global = false` + "\n" config += ` }]` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_template = "bfd_template1"` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_enable = true` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_local_address = "1.2.3.4"` + "\n" } config += ` ipv6_enable = true` + "\n" diff --git a/internal/provider/data_source_iosxe_interface_tunnel_test.go b/internal/provider/data_source_iosxe_interface_tunnel_test.go index 2720057f..38b94e76 100644 --- a/internal/provider/data_source_iosxe_interface_tunnel_test.go +++ b/internal/provider/data_source_iosxe_interface_tunnel_test.go @@ -60,13 +60,13 @@ func TestAccDataSourceIosxeInterfaceTunnel(t *testing.T) { if os.Getenv("C8000V") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_tunnel.test", "tunnel_mode_ipsec_ipv4", "true")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_tunnel.test", "bfd_template", "bfd_template1")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_tunnel.test", "bfd_enable", "true")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_interface_tunnel.test", "bfd_local_address", "1.2.3.4")) } resource.Test(t, resource.TestCase{ @@ -136,13 +136,13 @@ func testAccDataSourceIosxeInterfaceTunnelConfig() string { if os.Getenv("C8000V") != "" { config += ` tunnel_mode_ipsec_ipv4 = true` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_template = "bfd_template1"` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_enable = true` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_local_address = "1.2.3.4"` + "\n" } config += ` depends_on = [iosxe_restconf.PreReq0, ]` + "\n" diff --git a/internal/provider/data_source_iosxe_route_map_test.go b/internal/provider/data_source_iosxe_route_map_test.go index 45332dc4..012ec21a 100644 --- a/internal/provider/data_source_iosxe_route_map_test.go +++ b/internal/provider/data_source_iosxe_route_map_test.go @@ -56,10 +56,10 @@ func TestAccDataSourceIosxeRouteMap(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_route_map.test", "entries.0.match_tags.0", "100")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_route_map.test", "entries.0.match_track", "1")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_route_map.test", "entries.0.match_as_paths_legacy.0", "10")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_route_map.test", "entries.0.match_community_lists_legacy.0", "COMM1")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_route_map.test", "entries.0.match_extcommunity_lists_legacy.0", "EXTCOMM1")) } checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_route_map.test", "entries.0.match_local_preferences_legacy.0", "100")) @@ -150,10 +150,10 @@ func testAccDataSourceIosxeRouteMapConfig() string { config += ` match_tags = [100]` + "\n" config += ` match_track = 1` + "\n" config += ` match_as_paths_legacy = [10]` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` match_community_lists_legacy = ["COMM1"]` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` match_extcommunity_lists_legacy = ["EXTCOMM1"]` + "\n" } config += ` match_local_preferences_legacy = [100]` + "\n" diff --git a/internal/provider/data_source_iosxe_snmp_server_test.go b/internal/provider/data_source_iosxe_snmp_server_test.go index 51dde506..49933cde 100644 --- a/internal/provider/data_source_iosxe_snmp_server_test.go +++ b/internal/provider/data_source_iosxe_snmp_server_test.go @@ -48,7 +48,7 @@ func TestAccDataSourceIosxeSNMPServer(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_snmp_server.test", "hosts.0.encryption", "7")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_snmp_server.test", "system_shutdown", "true")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_snmp_server.test", "enable_traps_flowmon", "true")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_snmp_server.test", "enable_traps_entity_perf_throughput_notif", "true")) } checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_snmp_server.test", "enable_traps_call_home_message_send_fail", "true")) @@ -73,7 +73,9 @@ func TestAccDataSourceIosxeSNMPServer(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_snmp_server.test", "enable_traps_vlancreate", "true")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_snmp_server.test", "enable_traps_vlandelete", "true")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_snmp_server.test", "enable_traps_port_security", "true")) - checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_snmp_server.test", "enable_traps_license", "true")) + if os.Getenv("IOSXE176") != "" || os.Getenv("IOSXE179") != "" { + checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_snmp_server.test", "enable_traps_license", "true")) + } checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_snmp_server.test", "enable_traps_smart_license", "true")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_snmp_server.test", "enable_traps_cpu_threshold", "true")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_snmp_server.test", "enable_traps_memory_bufferpeak", "true")) @@ -89,7 +91,7 @@ func TestAccDataSourceIosxeSNMPServer(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_snmp_server.test", "enable_traps_fru_ctrl", "true")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_snmp_server.test", "enable_traps_flash_insertion", "true")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_snmp_server.test", "enable_traps_flash_removal", "true")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("data.iosxe_snmp_server.test", "enable_traps_flash_lowspace", "true")) } if os.Getenv("C9000V") != "" { @@ -223,7 +225,7 @@ func testAccDataSourceIosxeSNMPServerConfig() string { config += ` }]` + "\n" config += ` system_shutdown = true` + "\n" config += ` enable_traps_flowmon = true` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` enable_traps_entity_perf_throughput_notif = true` + "\n" } config += ` enable_traps_call_home_message_send_fail = true` + "\n" @@ -248,7 +250,9 @@ func testAccDataSourceIosxeSNMPServerConfig() string { config += ` enable_traps_vlancreate = true` + "\n" config += ` enable_traps_vlandelete = true` + "\n" config += ` enable_traps_port_security = true` + "\n" - config += ` enable_traps_license = true` + "\n" + if os.Getenv("IOSXE176") != "" || os.Getenv("IOSXE179") != "" { + config += ` enable_traps_license = true` + "\n" + } config += ` enable_traps_smart_license = true` + "\n" config += ` enable_traps_cpu_threshold = true` + "\n" config += ` enable_traps_memory_bufferpeak = true` + "\n" @@ -264,7 +268,7 @@ func testAccDataSourceIosxeSNMPServerConfig() string { config += ` enable_traps_fru_ctrl = true` + "\n" config += ` enable_traps_flash_insertion = true` + "\n" config += ` enable_traps_flash_removal = true` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` enable_traps_flash_lowspace = true` + "\n" } if os.Getenv("C9000V") != "" { diff --git a/internal/provider/resource_iosxe_aaa_accounting_test.go b/internal/provider/resource_iosxe_aaa_accounting_test.go index b63b6073..56e14fb7 100644 --- a/internal/provider/resource_iosxe_aaa_accounting_test.go +++ b/internal/provider/resource_iosxe_aaa_accounting_test.go @@ -29,7 +29,7 @@ import ( func TestAccIosxeAAAAccounting(t *testing.T) { var checks []resource.TestCheckFunc checks = append(checks, resource.TestCheckResourceAttr("iosxe_aaa_accounting.test", "update_newinfo_periodic", "2880")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_aaa_accounting.test", "identities.0.name", "test")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_aaa_accounting.test", "identities.0.start_stop_broadcast", "false")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_aaa_accounting.test", "identities.0.start_stop_group_broadcast", "false")) @@ -78,7 +78,7 @@ func testAccIosxeAAAAccountingConfig_minimum() string { func testAccIosxeAAAAccountingConfig_all() string { config := `resource "iosxe_aaa_accounting" "test" {` + "\n" config += ` update_newinfo_periodic = 2880` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` identities = [{` + "\n" config += ` name = "test"` + "\n" config += ` start_stop_broadcast = false` + "\n" diff --git a/internal/provider/resource_iosxe_bfd_template_multi_hop_test.go b/internal/provider/resource_iosxe_bfd_template_multi_hop_test.go index b56e9bde..d02ba3bd 100644 --- a/internal/provider/resource_iosxe_bfd_template_multi_hop_test.go +++ b/internal/provider/resource_iosxe_bfd_template_multi_hop_test.go @@ -30,13 +30,13 @@ func TestAccIosxeBFDTemplateMultiHop(t *testing.T) { var checks []resource.TestCheckFunc checks = append(checks, resource.TestCheckResourceAttr("iosxe_bfd_template_multi_hop.test", "name", "T11")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_bfd_template_multi_hop.test", "echo", "true")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_bfd_template_multi_hop.test", "interval_milliseconds_min_tx", "4500")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_bfd_template_multi_hop.test", "interval_milliseconds_min_rx", "5500")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_bfd_template_multi_hop.test", "interval_milliseconds_multiplier", "40")) } checks = append(checks, resource.TestCheckResourceAttr("iosxe_bfd_template_multi_hop.test", "authentication_md5_keychain", "KEYNAME")) @@ -75,13 +75,13 @@ func testAccIosxeBFDTemplateMultiHopConfig_all() string { config := `resource "iosxe_bfd_template_multi_hop" "test" {` + "\n" config += ` name = "T11"` + "\n" config += ` echo = true` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` interval_milliseconds_min_tx = 4500` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` interval_milliseconds_min_rx = 5500` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` interval_milliseconds_multiplier = 40` + "\n" } config += ` authentication_md5_keychain = "KEYNAME"` + "\n" diff --git a/internal/provider/resource_iosxe_bfd_template_single_hop_test.go b/internal/provider/resource_iosxe_bfd_template_single_hop_test.go index 1da1d5a6..adf335a6 100644 --- a/internal/provider/resource_iosxe_bfd_template_single_hop_test.go +++ b/internal/provider/resource_iosxe_bfd_template_single_hop_test.go @@ -30,13 +30,13 @@ func TestAccIosxeBFDTemplateSingleHop(t *testing.T) { var checks []resource.TestCheckFunc checks = append(checks, resource.TestCheckResourceAttr("iosxe_bfd_template_single_hop.test", "name", "SH-TEMPLATE-1")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_bfd_template_single_hop.test", "authentication_md5_keychain", "KEYC1")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_bfd_template_single_hop.test", "interval_milliseconds_min_tx", "200")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_bfd_template_single_hop.test", "interval_milliseconds_min_rx", "200")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_bfd_template_single_hop.test", "interval_milliseconds_multiplier", "4")) } checks = append(checks, resource.TestCheckResourceAttr("iosxe_bfd_template_single_hop.test", "echo", "true")) @@ -75,13 +75,13 @@ func testAccIosxeBFDTemplateSingleHopConfig_all() string { config := `resource "iosxe_bfd_template_single_hop" "test" {` + "\n" config += ` name = "SH-TEMPLATE-1"` + "\n" config += ` authentication_md5_keychain = "KEYC1"` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` interval_milliseconds_min_tx = 200` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` interval_milliseconds_min_rx = 200` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` interval_milliseconds_multiplier = 4` + "\n" } config += ` echo = true` + "\n" diff --git a/internal/provider/resource_iosxe_bgp_ipv4_unicast_vrf_neighbor_test.go b/internal/provider/resource_iosxe_bgp_ipv4_unicast_vrf_neighbor_test.go index 91795bed..b7984eac 100644 --- a/internal/provider/resource_iosxe_bgp_ipv4_unicast_vrf_neighbor_test.go +++ b/internal/provider/resource_iosxe_bgp_ipv4_unicast_vrf_neighbor_test.go @@ -20,6 +20,7 @@ package provider import ( + "os" "testing" "github.com/hashicorp/terraform-plugin-testing/helper/resource" @@ -31,7 +32,9 @@ func TestAccIosxeBGPIPv4UnicastVRFNeighbor(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("iosxe_bgp_ipv4_unicast_vrf_neighbor.test", "remote_as", "65000")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_bgp_ipv4_unicast_vrf_neighbor.test", "description", "BGP Neighbor Description")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_bgp_ipv4_unicast_vrf_neighbor.test", "shutdown", "false")) - checks = append(checks, resource.TestCheckResourceAttr("iosxe_bgp_ipv4_unicast_vrf_neighbor.test", "cluster_id", "2.2.2.2")) + if os.Getenv("IOSXE176") != "" || os.Getenv("IOSXE179") != "" { + checks = append(checks, resource.TestCheckResourceAttr("iosxe_bgp_ipv4_unicast_vrf_neighbor.test", "cluster_id", "2.2.2.2")) + } checks = append(checks, resource.TestCheckResourceAttr("iosxe_bgp_ipv4_unicast_vrf_neighbor.test", "log_neighbor_changes_disable", "true")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_bgp_ipv4_unicast_vrf_neighbor.test", "password_type", "1")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_bgp_ipv4_unicast_vrf_neighbor.test", "password", "LINE")) @@ -139,7 +142,9 @@ func testAccIosxeBGPIPv4UnicastVRFNeighborConfig_all() string { config += ` remote_as = "65000"` + "\n" config += ` description = "BGP Neighbor Description"` + "\n" config += ` shutdown = false` + "\n" - config += ` cluster_id = "2.2.2.2"` + "\n" + if os.Getenv("IOSXE176") != "" || os.Getenv("IOSXE179") != "" { + config += ` cluster_id = "2.2.2.2"` + "\n" + } config += ` log_neighbor_changes_disable = true` + "\n" config += ` password_type = 1` + "\n" config += ` password = "LINE"` + "\n" diff --git a/internal/provider/resource_iosxe_cli_test.go b/internal/provider/resource_iosxe_cli_test.go index fa261837..58da58cf 100644 --- a/internal/provider/resource_iosxe_cli_test.go +++ b/internal/provider/resource_iosxe_cli_test.go @@ -27,8 +27,8 @@ import ( ) func TestAccIosxeCli(t *testing.T) { - if os.Getenv("IOSXE179") == "" && os.Getenv("IOSXE1710") == "" { - t.Skip("skipping test, set environment variable IOSXE179 or IOSXE1710") + if os.Getenv("IOSXE179") == "" && os.Getenv("IOSXE1713") == "" { + t.Skip("skipping test, set environment variable IOSXE179 or IOSXE1713") } resource.Test(t, resource.TestCase{ PreCheck: func() { testAccPreCheck(t) }, diff --git a/internal/provider/resource_iosxe_errdisable_test.go b/internal/provider/resource_iosxe_errdisable_test.go index 7e83337a..c05abac1 100644 --- a/internal/provider/resource_iosxe_errdisable_test.go +++ b/internal/provider/resource_iosxe_errdisable_test.go @@ -40,7 +40,7 @@ func TestAccIosxeErrdisable(t *testing.T) { if os.Getenv("C9000V") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_errdisable.test", "detect_cause_security_violation_shutdown_vlan", "true")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_errdisable.test", "detect_cause_loopdetect", "true")) } checks = append(checks, resource.TestCheckResourceAttr("iosxe_errdisable.test", "flap_setting_cause_dtp_flap_max_flaps", "80")) @@ -90,7 +90,7 @@ func TestAccIosxeErrdisable(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("iosxe_errdisable.test", "recovery_cause_storm_control", "true")) } checks = append(checks, resource.TestCheckResourceAttr("iosxe_errdisable.test", "recovery_cause_udld", "true")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_errdisable.test", "recovery_cause_loopdetect", "true")) } resource.Test(t, resource.TestCase{ @@ -133,7 +133,7 @@ func testAccIosxeErrdisableConfig_all() string { if os.Getenv("C9000V") != "" { config += ` detect_cause_security_violation_shutdown_vlan = true` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` detect_cause_loopdetect = true` + "\n" } config += ` flap_setting_cause_dtp_flap_max_flaps = 80` + "\n" @@ -183,7 +183,7 @@ func testAccIosxeErrdisableConfig_all() string { config += ` recovery_cause_storm_control = true` + "\n" } config += ` recovery_cause_udld = true` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` recovery_cause_loopdetect = true` + "\n" } config += `}` + "\n" diff --git a/internal/provider/resource_iosxe_evpn_instance_test.go b/internal/provider/resource_iosxe_evpn_instance_test.go index 27b316f8..b1f190f9 100644 --- a/internal/provider/resource_iosxe_evpn_instance_test.go +++ b/internal/provider/resource_iosxe_evpn_instance_test.go @@ -39,8 +39,12 @@ func TestAccIosxeEVPNInstance(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("iosxe_evpn_instance.test", "vlan_based_encapsulation", "vxlan")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_evpn_instance.test", "vlan_based_auto_route_target", "false")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_evpn_instance.test", "vlan_based_rd", "10:10")) - checks = append(checks, resource.TestCheckResourceAttr("iosxe_evpn_instance.test", "vlan_based_route_target", "10:10")) - checks = append(checks, resource.TestCheckResourceAttr("iosxe_evpn_instance.test", "vlan_based_route_target_both", "10:10")) + if os.Getenv("IOSXE176") != "" || os.Getenv("IOSXE179") != "" { + checks = append(checks, resource.TestCheckResourceAttr("iosxe_evpn_instance.test", "vlan_based_route_target", "10:10")) + } + if os.Getenv("IOSXE176") != "" || os.Getenv("IOSXE179") != "" { + checks = append(checks, resource.TestCheckResourceAttr("iosxe_evpn_instance.test", "vlan_based_route_target_both", "10:10")) + } checks = append(checks, resource.TestCheckResourceAttr("iosxe_evpn_instance.test", "vlan_based_route_target_import", "10:10")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_evpn_instance.test", "vlan_based_route_target_export", "10:10")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_evpn_instance.test", "vlan_based_ip_local_learning_disable", "false")) @@ -81,8 +85,12 @@ func testAccIosxeEVPNInstanceConfig_all() string { config += ` vlan_based_encapsulation = "vxlan"` + "\n" config += ` vlan_based_auto_route_target = false` + "\n" config += ` vlan_based_rd = "10:10"` + "\n" - config += ` vlan_based_route_target = "10:10"` + "\n" - config += ` vlan_based_route_target_both = "10:10"` + "\n" + if os.Getenv("IOSXE176") != "" || os.Getenv("IOSXE179") != "" { + config += ` vlan_based_route_target = "10:10"` + "\n" + } + if os.Getenv("IOSXE176") != "" || os.Getenv("IOSXE179") != "" { + config += ` vlan_based_route_target_both = "10:10"` + "\n" + } config += ` vlan_based_route_target_import = "10:10"` + "\n" config += ` vlan_based_route_target_export = "10:10"` + "\n" config += ` vlan_based_ip_local_learning_disable = false` + "\n" diff --git a/internal/provider/resource_iosxe_interface_port_channel_subinterface_test.go b/internal/provider/resource_iosxe_interface_port_channel_subinterface_test.go index 53ac66ad..d02f53c8 100644 --- a/internal/provider/resource_iosxe_interface_port_channel_subinterface_test.go +++ b/internal/provider/resource_iosxe_interface_port_channel_subinterface_test.go @@ -47,13 +47,13 @@ func TestAccIosxeInterfacePortChannelSubinterface(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_port_channel_subinterface.test", "ip_access_group_out_enable", "true")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_port_channel_subinterface.test", "helper_addresses.0.address", "10.10.10.10")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_port_channel_subinterface.test", "helper_addresses.0.global", "false")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_port_channel_subinterface.test", "bfd_template", "bfd_template1")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_port_channel_subinterface.test", "bfd_enable", "true")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_port_channel_subinterface.test", "bfd_local_address", "1.2.3.4")) } checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_port_channel_subinterface.test", "ipv6_enable", "true")) @@ -146,13 +146,13 @@ func testAccIosxeInterfacePortChannelSubinterfaceConfig_all() string { config += ` address = "10.10.10.10"` + "\n" config += ` global = false` + "\n" config += ` }]` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_template = "bfd_template1"` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_enable = true` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_local_address = "1.2.3.4"` + "\n" } config += ` ipv6_enable = true` + "\n" diff --git a/internal/provider/resource_iosxe_interface_port_channel_test.go b/internal/provider/resource_iosxe_interface_port_channel_test.go index f1c82875..530039ee 100644 --- a/internal/provider/resource_iosxe_interface_port_channel_test.go +++ b/internal/provider/resource_iosxe_interface_port_channel_test.go @@ -53,13 +53,13 @@ func TestAccIosxeInterfacePortChannel(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_port_channel.test", "ip_dhcp_relay_source_interface", "Loopback100")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_port_channel.test", "helper_addresses.0.address", "10.10.10.10")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_port_channel.test", "helper_addresses.0.global", "false")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_port_channel.test", "bfd_template", "bfd_template1")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_port_channel.test", "bfd_enable", "true")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_port_channel.test", "bfd_local_address", "1.2.3.4")) } checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_port_channel.test", "ipv6_enable", "true")) @@ -146,13 +146,13 @@ func testAccIosxeInterfacePortChannelConfig_all() string { config += ` address = "10.10.10.10"` + "\n" config += ` global = false` + "\n" config += ` }]` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_template = "bfd_template1"` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_enable = true` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_local_address = "1.2.3.4"` + "\n" } config += ` ipv6_enable = true` + "\n" diff --git a/internal/provider/resource_iosxe_interface_tunnel_test.go b/internal/provider/resource_iosxe_interface_tunnel_test.go index d1d03c49..81d3dca3 100644 --- a/internal/provider/resource_iosxe_interface_tunnel_test.go +++ b/internal/provider/resource_iosxe_interface_tunnel_test.go @@ -61,13 +61,13 @@ func TestAccIosxeInterfaceTunnel(t *testing.T) { if os.Getenv("C8000V") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_tunnel.test", "tunnel_mode_ipsec_ipv4", "true")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_tunnel.test", "bfd_template", "bfd_template1")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_tunnel.test", "bfd_enable", "true")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_interface_tunnel.test", "bfd_local_address", "1.2.3.4")) } resource.Test(t, resource.TestCase{ @@ -152,13 +152,13 @@ func testAccIosxeInterfaceTunnelConfig_all() string { if os.Getenv("C8000V") != "" { config += ` tunnel_mode_ipsec_ipv4 = true` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_template = "bfd_template1"` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_enable = true` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` bfd_local_address = "1.2.3.4"` + "\n" } config += ` depends_on = [iosxe_restconf.PreReq0, ]` + "\n" diff --git a/internal/provider/resource_iosxe_route_map_test.go b/internal/provider/resource_iosxe_route_map_test.go index ebc477d0..3a907bfc 100644 --- a/internal/provider/resource_iosxe_route_map_test.go +++ b/internal/provider/resource_iosxe_route_map_test.go @@ -57,10 +57,10 @@ func TestAccIosxeRouteMap(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("iosxe_route_map.test", "entries.0.match_tags.0", "100")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_route_map.test", "entries.0.match_track", "1")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_route_map.test", "entries.0.match_as_paths_legacy.0", "10")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_route_map.test", "entries.0.match_community_lists_legacy.0", "COMM1")) } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_route_map.test", "entries.0.match_extcommunity_lists_legacy.0", "EXTCOMM1")) } checks = append(checks, resource.TestCheckResourceAttr("iosxe_route_map.test", "entries.0.match_local_preferences_legacy.0", "100")) @@ -167,10 +167,10 @@ func testAccIosxeRouteMapConfig_all() string { config += ` match_tags = [100]` + "\n" config += ` match_track = 1` + "\n" config += ` match_as_paths_legacy = [10]` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` match_community_lists_legacy = ["COMM1"]` + "\n" } - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` match_extcommunity_lists_legacy = ["EXTCOMM1"]` + "\n" } config += ` match_local_preferences_legacy = [100]` + "\n" diff --git a/internal/provider/resource_iosxe_snmp_server_test.go b/internal/provider/resource_iosxe_snmp_server_test.go index 1cfc254c..f761056c 100644 --- a/internal/provider/resource_iosxe_snmp_server_test.go +++ b/internal/provider/resource_iosxe_snmp_server_test.go @@ -48,7 +48,7 @@ func TestAccIosxeSNMPServer(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("iosxe_snmp_server.test", "hosts.0.encryption", "7")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_snmp_server.test", "system_shutdown", "true")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_snmp_server.test", "enable_traps_flowmon", "true")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_snmp_server.test", "enable_traps_entity_perf_throughput_notif", "true")) } checks = append(checks, resource.TestCheckResourceAttr("iosxe_snmp_server.test", "enable_traps_call_home_message_send_fail", "true")) @@ -73,7 +73,9 @@ func TestAccIosxeSNMPServer(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("iosxe_snmp_server.test", "enable_traps_vlancreate", "true")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_snmp_server.test", "enable_traps_vlandelete", "true")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_snmp_server.test", "enable_traps_port_security", "true")) - checks = append(checks, resource.TestCheckResourceAttr("iosxe_snmp_server.test", "enable_traps_license", "true")) + if os.Getenv("IOSXE176") != "" || os.Getenv("IOSXE179") != "" { + checks = append(checks, resource.TestCheckResourceAttr("iosxe_snmp_server.test", "enable_traps_license", "true")) + } checks = append(checks, resource.TestCheckResourceAttr("iosxe_snmp_server.test", "enable_traps_smart_license", "true")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_snmp_server.test", "enable_traps_cpu_threshold", "true")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_snmp_server.test", "enable_traps_memory_bufferpeak", "true")) @@ -89,7 +91,7 @@ func TestAccIosxeSNMPServer(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("iosxe_snmp_server.test", "enable_traps_fru_ctrl", "true")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_snmp_server.test", "enable_traps_flash_insertion", "true")) checks = append(checks, resource.TestCheckResourceAttr("iosxe_snmp_server.test", "enable_traps_flash_removal", "true")) - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { checks = append(checks, resource.TestCheckResourceAttr("iosxe_snmp_server.test", "enable_traps_flash_lowspace", "true")) } if os.Getenv("C9000V") != "" { @@ -237,7 +239,7 @@ func testAccIosxeSNMPServerConfig_all() string { config += ` }]` + "\n" config += ` system_shutdown = true` + "\n" config += ` enable_traps_flowmon = true` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` enable_traps_entity_perf_throughput_notif = true` + "\n" } config += ` enable_traps_call_home_message_send_fail = true` + "\n" @@ -262,7 +264,9 @@ func testAccIosxeSNMPServerConfig_all() string { config += ` enable_traps_vlancreate = true` + "\n" config += ` enable_traps_vlandelete = true` + "\n" config += ` enable_traps_port_security = true` + "\n" - config += ` enable_traps_license = true` + "\n" + if os.Getenv("IOSXE176") != "" || os.Getenv("IOSXE179") != "" { + config += ` enable_traps_license = true` + "\n" + } config += ` enable_traps_smart_license = true` + "\n" config += ` enable_traps_cpu_threshold = true` + "\n" config += ` enable_traps_memory_bufferpeak = true` + "\n" @@ -278,7 +282,7 @@ func testAccIosxeSNMPServerConfig_all() string { config += ` enable_traps_fru_ctrl = true` + "\n" config += ` enable_traps_flash_insertion = true` + "\n" config += ` enable_traps_flash_removal = true` + "\n" - if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1710") != "" { + if os.Getenv("IOSXE179") != "" || os.Getenv("IOSXE1713") != "" { config += ` enable_traps_flash_lowspace = true` + "\n" } if os.Getenv("C9000V") != "" { diff --git a/templates/index.md.tmpl b/templates/index.md.tmpl index fe4e74e6..511a0224 100644 --- a/templates/index.md.tmpl +++ b/templates/index.md.tmpl @@ -27,7 +27,7 @@ All resources and data sources have been tested with the following releases. | -------------- | ------- | | Catalyst 8000v | 17.6.5 | | Catalyst 8000v | 17.9.4 | -| Catalyst 9000v | 17.10.1 | +| Catalyst 9000v | 17.13.1 | ## Example Usage