From 85a87e2c925f9eaec6c31c5cb27c4d481ab007c4 Mon Sep 17 00:00:00 2001 From: Louay Alakkad Date: Mon, 4 Jun 2018 19:46:08 +0100 Subject: [PATCH] Fix broken test --- uptimerobot/resource_uptimerobot_status_page.go | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/uptimerobot/resource_uptimerobot_status_page.go b/uptimerobot/resource_uptimerobot_status_page.go index 5496eae..7d2b86d 100644 --- a/uptimerobot/resource_uptimerobot_status_page.go +++ b/uptimerobot/resource_uptimerobot_status_page.go @@ -64,9 +64,12 @@ func resourceStatusPage() *schema.Resource { Type: schema.TypeInt, }, PromoteSingle: true, - // DefaultFunc: func() (interface{}, error) { - // return []int{0}, nil - // }, + DiffSuppressFunc: func(k, old, new string, d *schema.ResourceData) bool { + if k == "monitors.#" && old == "1" && new == "0" && d.Get("monitors.0").(int) == 0 { + return true + } + return false + }, }, "dns_address": &schema.Schema{ Type: schema.TypeString,