provider/digitalocean: Mark not_after and sha1_fingerprint as computed

This commit is contained in:
Caio Filipini 2017-05-26 16:21:08 +02:00
parent 32d724ee0d
commit 2b12ddffd0
2 changed files with 3 additions and 4 deletions

View File

@ -44,12 +44,14 @@ func resourceDigitalOceanCertificate() *schema.Resource {
Type: schema.TypeString,
Optional: true,
ForceNew: true,
Computed: true,
},
"sha1_fingerprint": {
Type: schema.TypeString,
Optional: true,
ForceNew: true,
Computed: true,
},
},
}

View File

@ -31,8 +31,7 @@ func TestAccDigitalOceanCertificate_Basic(t *testing.T) {
CheckDestroy: testAccCheckDigitalOceanCertificateDestroy,
Steps: []resource.TestStep{
{
ExpectNonEmptyPlan: true,
Config: testAccCheckDigitalOceanCertificateConfig_basic(rInt, privateKeyMaterial, leafCertMaterial, certChainMaterial),
Config: testAccCheckDigitalOceanCertificateConfig_basic(rInt, privateKeyMaterial, leafCertMaterial, certChainMaterial),
Check: resource.ComposeTestCheckFunc(
testAccCheckDigitalOceanCertificateExists("digitalocean_certificate.foobar", &cert),
resource.TestCheckResourceAttr(
@ -105,11 +104,9 @@ resource "digitalocean_certificate" "foobar" {
private_key = <<EOF
%s
EOF
leaf_certificate = <<EOF
%s
EOF
certificate_chain = <<EOF
%s
EOF