From 7156fc455614fa34fb4d888b733a3695a9b31927 Mon Sep 17 00:00:00 2001 From: danischm Date: Sat, 29 Jul 2023 09:18:04 +0200 Subject: [PATCH] Fix bfd resource and data source --- .github/workflows/test.yml | 2 +- docs/data-sources/bfd.md | 2 +- docs/resources/bfd.md | 16 +-- examples/resources/iosxr_bfd/resource.tf | 14 +-- gen/definitions/bfd.yaml | 4 +- internal/provider/data_source_iosxr_bfd.go | 2 +- .../provider/data_source_iosxr_bfd_test.go | 4 +- internal/provider/model_iosxr_bfd.go | 116 +++++++++--------- internal/provider/resource_iosxr_bfd.go | 2 +- internal/provider/resource_iosxr_bfd_test.go | 4 +- 10 files changed, 83 insertions(+), 83 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 71ae28cb..12860e45 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -29,7 +29,7 @@ jobs: build: name: Build runs-on: ubuntu-latest - timeout-minutes: 5 + timeout-minutes: 10 steps: - uses: actions/checkout@v3 - uses: actions/setup-python@v4 diff --git a/docs/data-sources/bfd.md b/docs/data-sources/bfd.md index b7ce37e8..59d6cf60 100644 --- a/docs/data-sources/bfd.md +++ b/docs/data-sources/bfd.md @@ -39,7 +39,7 @@ data "iosxr_bfd" "example" { - `dampening_secondary_wait` (Number) Secondary delay before bringing up session - `dampening_threshold` (Number) Stability threshold to enable dampening - `echo_disable` (Boolean) Disable BFD echo mode -- `echo_ipv4_bundle_per_member_minimum_interval_preferred_minimum_interval` (Number) The preferred minimum interval (in ms) for the BFD session +- `echo_ipv4_bundle_per_member_preferred_minimum_interval` (Number) The preferred minimum interval (in ms) for the BFD session - `echo_ipv4_source` (String) BFD echo source IP address - `echo_latency_detect_count` (Number) Count of consecutive bad latency packets to take session down - `echo_latency_detect_percentage` (Number) Percentage of detection time to consider as bad latency diff --git a/docs/resources/bfd.md b/docs/resources/bfd.md index 9dd7c444..14f3001d 100644 --- a/docs/resources/bfd.md +++ b/docs/resources/bfd.md @@ -14,13 +14,13 @@ This resource can manage the BFD configuration. ```terraform resource "iosxr_bfd" "example" { - echo_disable = true - echo_latency_detect_percentage = 200 - echo_latency_detect_count = 10 - echo_startup_validate_force = true - echo_ipv4_source = "10.1.1.1" - echo_ipv4_bundle_per_member_minimum_interval_preferred_minimum_interval = 200 - trap_singlehop_pre_mapped = true + echo_disable = true + echo_latency_detect_percentage = 200 + echo_latency_detect_count = 10 + echo_startup_validate_force = true + echo_ipv4_source = "10.1.1.1" + echo_ipv4_bundle_per_member_preferred_minimum_interval = 200 + trap_singlehop_pre_mapped = true multipath_locations = [ { location_name = "0/0/CPU0" @@ -84,7 +84,7 @@ resource "iosxr_bfd" "example" { - Choices: `all`, `attributes` - `device` (String) A device name from the provider configuration. - `echo_disable` (Boolean) Disable BFD echo mode -- `echo_ipv4_bundle_per_member_minimum_interval_preferred_minimum_interval` (Number) The preferred minimum interval (in ms) for the BFD session +- `echo_ipv4_bundle_per_member_preferred_minimum_interval` (Number) The preferred minimum interval (in ms) for the BFD session - Range: `15`-`2000` - `echo_ipv4_source` (String) BFD echo source IP address - `echo_latency_detect_count` (Number) Count of consecutive bad latency packets to take session down diff --git a/examples/resources/iosxr_bfd/resource.tf b/examples/resources/iosxr_bfd/resource.tf index cd8a8fa1..f61a6d59 100644 --- a/examples/resources/iosxr_bfd/resource.tf +++ b/examples/resources/iosxr_bfd/resource.tf @@ -1,11 +1,11 @@ resource "iosxr_bfd" "example" { - echo_disable = true - echo_latency_detect_percentage = 200 - echo_latency_detect_count = 10 - echo_startup_validate_force = true - echo_ipv4_source = "10.1.1.1" - echo_ipv4_bundle_per_member_minimum_interval_preferred_minimum_interval = 200 - trap_singlehop_pre_mapped = true + echo_disable = true + echo_latency_detect_percentage = 200 + echo_latency_detect_count = 10 + echo_startup_validate_force = true + echo_ipv4_source = "10.1.1.1" + echo_ipv4_bundle_per_member_preferred_minimum_interval = 200 + trap_singlehop_pre_mapped = true multipath_locations = [ { location_name = "0/0/CPU0" diff --git a/gen/definitions/bfd.yaml b/gen/definitions/bfd.yaml index 400a4f6b..5697f003 100644 --- a/gen/definitions/bfd.yaml +++ b/gen/definitions/bfd.yaml @@ -14,6 +14,7 @@ attributes: - yang_name: echo/ipv4/source example: 10.1.1.1 - yang_name: echo/ipv4/bundle-per-member/minimum-interval/preferred-minimum-interval + tf_name: echo_ipv4_bundle_per_member_preferred_minimum_interval example: 200 - yang_name: trap/singlehop/pre-mapped example: true @@ -24,7 +25,6 @@ attributes: - yang_name: location-name id: true example: 0/0/CPU0 - - yang_name: multihop/ttl-drop-threshold example: 200 - yang_name: dampening/initial-wait @@ -75,4 +75,4 @@ attributes: - yang_name: multiplier example: 40 - yang_name: ipv6/checksum/disable - example: true \ No newline at end of file + example: true diff --git a/internal/provider/data_source_iosxr_bfd.go b/internal/provider/data_source_iosxr_bfd.go index 2025237a..749f2d3c 100644 --- a/internal/provider/data_source_iosxr_bfd.go +++ b/internal/provider/data_source_iosxr_bfd.go @@ -82,7 +82,7 @@ func (d *BFDDataSource) Schema(ctx context.Context, req datasource.SchemaRequest MarkdownDescription: "BFD echo source IP address", Computed: true, }, - "echo_ipv4_bundle_per_member_minimum_interval_preferred_minimum_interval": schema.Int64Attribute{ + "echo_ipv4_bundle_per_member_preferred_minimum_interval": schema.Int64Attribute{ MarkdownDescription: "The preferred minimum interval (in ms) for the BFD session", Computed: true, }, diff --git a/internal/provider/data_source_iosxr_bfd_test.go b/internal/provider/data_source_iosxr_bfd_test.go index 3e340b77..116ceaa5 100644 --- a/internal/provider/data_source_iosxr_bfd_test.go +++ b/internal/provider/data_source_iosxr_bfd_test.go @@ -32,7 +32,7 @@ func TestAccDataSourceIosxrBFD(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("data.iosxr_bfd.test", "echo_latency_detect_count", "10")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxr_bfd.test", "echo_startup_validate_force", "true")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxr_bfd.test", "echo_ipv4_source", "10.1.1.1")) - checks = append(checks, resource.TestCheckResourceAttr("data.iosxr_bfd.test", "echo_ipv4_bundle_per_member_minimum_interval_preferred_minimum_interval", "200")) + checks = append(checks, resource.TestCheckResourceAttr("data.iosxr_bfd.test", "echo_ipv4_bundle_per_member_preferred_minimum_interval", "200")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxr_bfd.test", "trap_singlehop_pre_mapped", "true")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxr_bfd.test", "multipath_locations.0.location_name", "0/0/CPU0")) checks = append(checks, resource.TestCheckResourceAttr("data.iosxr_bfd.test", "multihop_ttl_drop_threshold", "200")) @@ -78,7 +78,7 @@ func testAccDataSourceIosxrBFDConfig() string { config += ` echo_latency_detect_count = 10` + "\n" config += ` echo_startup_validate_force = true` + "\n" config += ` echo_ipv4_source = "10.1.1.1"` + "\n" - config += ` echo_ipv4_bundle_per_member_minimum_interval_preferred_minimum_interval = 200` + "\n" + config += ` echo_ipv4_bundle_per_member_preferred_minimum_interval = 200` + "\n" config += ` trap_singlehop_pre_mapped = true` + "\n" config += ` multipath_locations = [{` + "\n" config += ` location_name = "0/0/CPU0"` + "\n" diff --git a/internal/provider/model_iosxr_bfd.go b/internal/provider/model_iosxr_bfd.go index ceb93dba..5bcad70e 100644 --- a/internal/provider/model_iosxr_bfd.go +++ b/internal/provider/model_iosxr_bfd.go @@ -31,60 +31,60 @@ import ( ) type BFD struct { - Device types.String `tfsdk:"device"` - Id types.String `tfsdk:"id"` - DeleteMode types.String `tfsdk:"delete_mode"` - EchoDisable types.Bool `tfsdk:"echo_disable"` - EchoLatencyDetectPercentage types.Int64 `tfsdk:"echo_latency_detect_percentage"` - EchoLatencyDetectCount types.Int64 `tfsdk:"echo_latency_detect_count"` - EchoStartupValidateForce types.Bool `tfsdk:"echo_startup_validate_force"` - EchoIpv4Source types.String `tfsdk:"echo_ipv4_source"` - EchoIpv4BundlePerMemberMinimumIntervalPreferredMinimumInterval types.Int64 `tfsdk:"echo_ipv4_bundle_per_member_minimum_interval_preferred_minimum_interval"` - TrapSinglehopPreMapped types.Bool `tfsdk:"trap_singlehop_pre_mapped"` - MultipathLocations []BFDMultipathLocations `tfsdk:"multipath_locations"` - MultihopTtlDropThreshold types.Int64 `tfsdk:"multihop_ttl_drop_threshold"` - DampeningInitialWait types.Int64 `tfsdk:"dampening_initial_wait"` - DampeningSecondaryWait types.Int64 `tfsdk:"dampening_secondary_wait"` - DampeningMaximumWait types.Int64 `tfsdk:"dampening_maximum_wait"` - DampeningThreshold types.Int64 `tfsdk:"dampening_threshold"` - DampeningExtensionsDownMonitoring types.Bool `tfsdk:"dampening_extensions_down_monitoring"` - DampeningDisable types.Bool `tfsdk:"dampening_disable"` - DampeningBundleMemberL3OnlyMode types.Bool `tfsdk:"dampening_bundle_member_l3_only_mode"` - DampeningBundleMemberInitialWait types.Int64 `tfsdk:"dampening_bundle_member_initial_wait"` - DampeningBundleMemberSecondaryWait types.Int64 `tfsdk:"dampening_bundle_member_secondary_wait"` - DampeningBundleMemberMaximumWait types.Int64 `tfsdk:"dampening_bundle_member_maximum_wait"` - BundleCoexistenceBobBlbInherit types.Bool `tfsdk:"bundle_coexistence_bob_blb_inherit"` - BundleCoexistenceBobBlbLogical types.Bool `tfsdk:"bundle_coexistence_bob_blb_logical"` - Interfaces []BFDInterfaces `tfsdk:"interfaces"` - Ipv6ChecksumDisable types.Bool `tfsdk:"ipv6_checksum_disable"` + Device types.String `tfsdk:"device"` + Id types.String `tfsdk:"id"` + DeleteMode types.String `tfsdk:"delete_mode"` + EchoDisable types.Bool `tfsdk:"echo_disable"` + EchoLatencyDetectPercentage types.Int64 `tfsdk:"echo_latency_detect_percentage"` + EchoLatencyDetectCount types.Int64 `tfsdk:"echo_latency_detect_count"` + EchoStartupValidateForce types.Bool `tfsdk:"echo_startup_validate_force"` + EchoIpv4Source types.String `tfsdk:"echo_ipv4_source"` + EchoIpv4BundlePerMemberPreferredMinimumInterval types.Int64 `tfsdk:"echo_ipv4_bundle_per_member_preferred_minimum_interval"` + TrapSinglehopPreMapped types.Bool `tfsdk:"trap_singlehop_pre_mapped"` + MultipathLocations []BFDMultipathLocations `tfsdk:"multipath_locations"` + MultihopTtlDropThreshold types.Int64 `tfsdk:"multihop_ttl_drop_threshold"` + DampeningInitialWait types.Int64 `tfsdk:"dampening_initial_wait"` + DampeningSecondaryWait types.Int64 `tfsdk:"dampening_secondary_wait"` + DampeningMaximumWait types.Int64 `tfsdk:"dampening_maximum_wait"` + DampeningThreshold types.Int64 `tfsdk:"dampening_threshold"` + DampeningExtensionsDownMonitoring types.Bool `tfsdk:"dampening_extensions_down_monitoring"` + DampeningDisable types.Bool `tfsdk:"dampening_disable"` + DampeningBundleMemberL3OnlyMode types.Bool `tfsdk:"dampening_bundle_member_l3_only_mode"` + DampeningBundleMemberInitialWait types.Int64 `tfsdk:"dampening_bundle_member_initial_wait"` + DampeningBundleMemberSecondaryWait types.Int64 `tfsdk:"dampening_bundle_member_secondary_wait"` + DampeningBundleMemberMaximumWait types.Int64 `tfsdk:"dampening_bundle_member_maximum_wait"` + BundleCoexistenceBobBlbInherit types.Bool `tfsdk:"bundle_coexistence_bob_blb_inherit"` + BundleCoexistenceBobBlbLogical types.Bool `tfsdk:"bundle_coexistence_bob_blb_logical"` + Interfaces []BFDInterfaces `tfsdk:"interfaces"` + Ipv6ChecksumDisable types.Bool `tfsdk:"ipv6_checksum_disable"` } type BFDData struct { - Device types.String `tfsdk:"device"` - Id types.String `tfsdk:"id"` - EchoDisable types.Bool `tfsdk:"echo_disable"` - EchoLatencyDetectPercentage types.Int64 `tfsdk:"echo_latency_detect_percentage"` - EchoLatencyDetectCount types.Int64 `tfsdk:"echo_latency_detect_count"` - EchoStartupValidateForce types.Bool `tfsdk:"echo_startup_validate_force"` - EchoIpv4Source types.String `tfsdk:"echo_ipv4_source"` - EchoIpv4BundlePerMemberMinimumIntervalPreferredMinimumInterval types.Int64 `tfsdk:"echo_ipv4_bundle_per_member_minimum_interval_preferred_minimum_interval"` - TrapSinglehopPreMapped types.Bool `tfsdk:"trap_singlehop_pre_mapped"` - MultipathLocations []BFDMultipathLocations `tfsdk:"multipath_locations"` - MultihopTtlDropThreshold types.Int64 `tfsdk:"multihop_ttl_drop_threshold"` - DampeningInitialWait types.Int64 `tfsdk:"dampening_initial_wait"` - DampeningSecondaryWait types.Int64 `tfsdk:"dampening_secondary_wait"` - DampeningMaximumWait types.Int64 `tfsdk:"dampening_maximum_wait"` - DampeningThreshold types.Int64 `tfsdk:"dampening_threshold"` - DampeningExtensionsDownMonitoring types.Bool `tfsdk:"dampening_extensions_down_monitoring"` - DampeningDisable types.Bool `tfsdk:"dampening_disable"` - DampeningBundleMemberL3OnlyMode types.Bool `tfsdk:"dampening_bundle_member_l3_only_mode"` - DampeningBundleMemberInitialWait types.Int64 `tfsdk:"dampening_bundle_member_initial_wait"` - DampeningBundleMemberSecondaryWait types.Int64 `tfsdk:"dampening_bundle_member_secondary_wait"` - DampeningBundleMemberMaximumWait types.Int64 `tfsdk:"dampening_bundle_member_maximum_wait"` - BundleCoexistenceBobBlbInherit types.Bool `tfsdk:"bundle_coexistence_bob_blb_inherit"` - BundleCoexistenceBobBlbLogical types.Bool `tfsdk:"bundle_coexistence_bob_blb_logical"` - Interfaces []BFDInterfaces `tfsdk:"interfaces"` - Ipv6ChecksumDisable types.Bool `tfsdk:"ipv6_checksum_disable"` + Device types.String `tfsdk:"device"` + Id types.String `tfsdk:"id"` + EchoDisable types.Bool `tfsdk:"echo_disable"` + EchoLatencyDetectPercentage types.Int64 `tfsdk:"echo_latency_detect_percentage"` + EchoLatencyDetectCount types.Int64 `tfsdk:"echo_latency_detect_count"` + EchoStartupValidateForce types.Bool `tfsdk:"echo_startup_validate_force"` + EchoIpv4Source types.String `tfsdk:"echo_ipv4_source"` + EchoIpv4BundlePerMemberPreferredMinimumInterval types.Int64 `tfsdk:"echo_ipv4_bundle_per_member_preferred_minimum_interval"` + TrapSinglehopPreMapped types.Bool `tfsdk:"trap_singlehop_pre_mapped"` + MultipathLocations []BFDMultipathLocations `tfsdk:"multipath_locations"` + MultihopTtlDropThreshold types.Int64 `tfsdk:"multihop_ttl_drop_threshold"` + DampeningInitialWait types.Int64 `tfsdk:"dampening_initial_wait"` + DampeningSecondaryWait types.Int64 `tfsdk:"dampening_secondary_wait"` + DampeningMaximumWait types.Int64 `tfsdk:"dampening_maximum_wait"` + DampeningThreshold types.Int64 `tfsdk:"dampening_threshold"` + DampeningExtensionsDownMonitoring types.Bool `tfsdk:"dampening_extensions_down_monitoring"` + DampeningDisable types.Bool `tfsdk:"dampening_disable"` + DampeningBundleMemberL3OnlyMode types.Bool `tfsdk:"dampening_bundle_member_l3_only_mode"` + DampeningBundleMemberInitialWait types.Int64 `tfsdk:"dampening_bundle_member_initial_wait"` + DampeningBundleMemberSecondaryWait types.Int64 `tfsdk:"dampening_bundle_member_secondary_wait"` + DampeningBundleMemberMaximumWait types.Int64 `tfsdk:"dampening_bundle_member_maximum_wait"` + BundleCoexistenceBobBlbInherit types.Bool `tfsdk:"bundle_coexistence_bob_blb_inherit"` + BundleCoexistenceBobBlbLogical types.Bool `tfsdk:"bundle_coexistence_bob_blb_logical"` + Interfaces []BFDInterfaces `tfsdk:"interfaces"` + Ipv6ChecksumDisable types.Bool `tfsdk:"ipv6_checksum_disable"` } type BFDMultipathLocations struct { LocationName types.String `tfsdk:"location_name"` @@ -130,8 +130,8 @@ func (data BFD) toBody(ctx context.Context) string { if !data.EchoIpv4Source.IsNull() && !data.EchoIpv4Source.IsUnknown() { body, _ = sjson.Set(body, "echo.ipv4.source", data.EchoIpv4Source.ValueString()) } - if !data.EchoIpv4BundlePerMemberMinimumIntervalPreferredMinimumInterval.IsNull() && !data.EchoIpv4BundlePerMemberMinimumIntervalPreferredMinimumInterval.IsUnknown() { - body, _ = sjson.Set(body, "echo.ipv4.bundle-per-member.minimum-interval.preferred-minimum-interval", strconv.FormatInt(data.EchoIpv4BundlePerMemberMinimumIntervalPreferredMinimumInterval.ValueInt64(), 10)) + if !data.EchoIpv4BundlePerMemberPreferredMinimumInterval.IsNull() && !data.EchoIpv4BundlePerMemberPreferredMinimumInterval.IsUnknown() { + body, _ = sjson.Set(body, "echo.ipv4.bundle-per-member.minimum-interval.preferred-minimum-interval", strconv.FormatInt(data.EchoIpv4BundlePerMemberPreferredMinimumInterval.ValueInt64(), 10)) } if !data.TrapSinglehopPreMapped.IsNull() && !data.TrapSinglehopPreMapped.IsUnknown() { if data.TrapSinglehopPreMapped.ValueBool() { @@ -275,10 +275,10 @@ func (data *BFD) updateFromBody(ctx context.Context, res []byte) { } else { data.EchoIpv4Source = types.StringNull() } - if value := gjson.GetBytes(res, "echo.ipv4.bundle-per-member.minimum-interval.preferred-minimum-interval"); value.Exists() && !data.EchoIpv4BundlePerMemberMinimumIntervalPreferredMinimumInterval.IsNull() { - data.EchoIpv4BundlePerMemberMinimumIntervalPreferredMinimumInterval = types.Int64Value(value.Int()) + if value := gjson.GetBytes(res, "echo.ipv4.bundle-per-member.minimum-interval.preferred-minimum-interval"); value.Exists() && !data.EchoIpv4BundlePerMemberPreferredMinimumInterval.IsNull() { + data.EchoIpv4BundlePerMemberPreferredMinimumInterval = types.Int64Value(value.Int()) } else { - data.EchoIpv4BundlePerMemberMinimumIntervalPreferredMinimumInterval = types.Int64Null() + data.EchoIpv4BundlePerMemberPreferredMinimumInterval = types.Int64Null() } if value := gjson.GetBytes(res, "trap.singlehop.pre-mapped"); !data.TrapSinglehopPreMapped.IsNull() { if value.Exists() { @@ -516,7 +516,7 @@ func (data *BFDData) fromBody(ctx context.Context, res []byte) { data.EchoIpv4Source = types.StringValue(value.String()) } if value := gjson.GetBytes(res, "echo.ipv4.bundle-per-member.minimum-interval.preferred-minimum-interval"); value.Exists() { - data.EchoIpv4BundlePerMemberMinimumIntervalPreferredMinimumInterval = types.Int64Value(value.Int()) + data.EchoIpv4BundlePerMemberPreferredMinimumInterval = types.Int64Value(value.Int()) } if value := gjson.GetBytes(res, "trap.singlehop.pre-mapped"); value.Exists() { data.TrapSinglehopPreMapped = types.BoolValue(true) @@ -770,7 +770,7 @@ func (data *BFD) getDeletePaths(ctx context.Context) []string { if !data.EchoIpv4Source.IsNull() { deletePaths = append(deletePaths, fmt.Sprintf("%v/echo/ipv4/source", data.getPath())) } - if !data.EchoIpv4BundlePerMemberMinimumIntervalPreferredMinimumInterval.IsNull() { + if !data.EchoIpv4BundlePerMemberPreferredMinimumInterval.IsNull() { deletePaths = append(deletePaths, fmt.Sprintf("%v/echo/ipv4/bundle-per-member/minimum-interval/preferred-minimum-interval", data.getPath())) } if !data.TrapSinglehopPreMapped.IsNull() { diff --git a/internal/provider/resource_iosxr_bfd.go b/internal/provider/resource_iosxr_bfd.go index 2a73c473..5a86766f 100644 --- a/internal/provider/resource_iosxr_bfd.go +++ b/internal/provider/resource_iosxr_bfd.go @@ -104,7 +104,7 @@ func (r *BFDResource) Schema(ctx context.Context, req resource.SchemaRequest, re stringvalidator.RegexMatches(regexp.MustCompile(`[0-9\.]*`), ""), }, }, - "echo_ipv4_bundle_per_member_minimum_interval_preferred_minimum_interval": schema.Int64Attribute{ + "echo_ipv4_bundle_per_member_preferred_minimum_interval": schema.Int64Attribute{ MarkdownDescription: helpers.NewAttributeDescription("The preferred minimum interval (in ms) for the BFD session").AddIntegerRangeDescription(15, 2000).String, Optional: true, Validators: []validator.Int64{ diff --git a/internal/provider/resource_iosxr_bfd_test.go b/internal/provider/resource_iosxr_bfd_test.go index 98f2ca19..5e7bacc4 100644 --- a/internal/provider/resource_iosxr_bfd_test.go +++ b/internal/provider/resource_iosxr_bfd_test.go @@ -33,7 +33,7 @@ func TestAccIosxrBFD(t *testing.T) { checks = append(checks, resource.TestCheckResourceAttr("iosxr_bfd.test", "echo_latency_detect_count", "10")) checks = append(checks, resource.TestCheckResourceAttr("iosxr_bfd.test", "echo_startup_validate_force", "true")) checks = append(checks, resource.TestCheckResourceAttr("iosxr_bfd.test", "echo_ipv4_source", "10.1.1.1")) - checks = append(checks, resource.TestCheckResourceAttr("iosxr_bfd.test", "echo_ipv4_bundle_per_member_minimum_interval_preferred_minimum_interval", "200")) + checks = append(checks, resource.TestCheckResourceAttr("iosxr_bfd.test", "echo_ipv4_bundle_per_member_preferred_minimum_interval", "200")) checks = append(checks, resource.TestCheckResourceAttr("iosxr_bfd.test", "trap_singlehop_pre_mapped", "true")) checks = append(checks, resource.TestCheckResourceAttr("iosxr_bfd.test", "multipath_locations.0.location_name", "0/0/CPU0")) checks = append(checks, resource.TestCheckResourceAttr("iosxr_bfd.test", "multihop_ttl_drop_threshold", "200")) @@ -94,7 +94,7 @@ func testAccIosxrBFDConfig_all() string { config += ` echo_latency_detect_count = 10` + "\n" config += ` echo_startup_validate_force = true` + "\n" config += ` echo_ipv4_source = "10.1.1.1"` + "\n" - config += ` echo_ipv4_bundle_per_member_minimum_interval_preferred_minimum_interval = 200` + "\n" + config += ` echo_ipv4_bundle_per_member_preferred_minimum_interval = 200` + "\n" config += ` trap_singlehop_pre_mapped = true` + "\n" config += ` multipath_locations = [{` + "\n" config += ` location_name = "0/0/CPU0"` + "\n"