fix acceptance test configuration

This commit is contained in:
Marin Salinas
2019-07-18 09:39:08 -07:00
committed by Megan Marsh
parent 571ef828e6
commit 683431afa2
3 changed files with 17 additions and 25 deletions
+6 -8
View File
@@ -1,7 +1,4 @@
/*
Deregister the test image with
aws oapi deregister-image --image-id $(aws oapi describe-images --output text --filters "Name=name,Values=packer-test-packer-test-dereg" --query 'Images[*].{ID:ImageId}')
*/
//TODO: explain how to delete the image.
package bsu
import (
@@ -16,9 +13,10 @@ import (
func TestBuilderAcc_basic(t *testing.T) {
builderT.Test(t, builderT.TestCase{
PreCheck: func() { testAccPreCheck(t) },
Builder: &Builder{},
Template: testBuilderAccBasic,
PreCheck: func() { testAccPreCheck(t) },
Builder: &Builder{},
Template: testBuilderAccBasic,
SkipArtifactTeardown: true,
})
}
@@ -47,7 +45,7 @@ const testBuilderAccBasic = `
"type": "test",
"region": "eu-west-2",
"vm_type": "t2.micro",
"source_omi": "ami-46260446",
"source_omi": "ami-65efcc11",
"ssh_username": "outscale",
"omi_name": "packer-test {{timestamp}}"
}]
+9 -7
View File
@@ -12,9 +12,10 @@ import (
func TestBuilderAcc_basic(t *testing.T) {
builderT.Test(t, builderT.TestCase{
PreCheck: func() { testAccPreCheck(t) },
Builder: &Builder{},
Template: testBuilderAccBasic,
PreCheck: func() { testAccPreCheck(t) },
Builder: &Builder{},
Template: testBuilderAccBasic,
SkipArtifactTeardown: true,
})
}
@@ -26,9 +27,9 @@ const testBuilderAccBasic = `
"builders": [{
"type": "test",
"region": "eu-west-2",
"vm_type": "c4.large",
"source_omi": "ami-46260446",
"ssh_username": "ubuntu",
"vm_type": "t2.micro",
"source_omi": "ami-65efcc11",
"ssh_username": "outscale",
"omi_name": "packer-test {{timestamp}}",
"omi_virtualization_type": "hvm",
"subregion_name": "eu-west-2a",
@@ -38,7 +39,8 @@ const testBuilderAccBasic = `
"device_name" : "/dev/xvdf",
"delete_on_vm_deletion" : false,
"volume_size" : 10,
"iops": 300
"iops": 300,
"no_device": 0
}
],
"omi_root_device":{
+2 -10
View File
@@ -23,19 +23,11 @@ const testBuilderAccBasic = `
"builders": [{
"type": "test",
"region": "eu-west-2",
"source_omi": "ami-99466096",
"source_omi": "ami-65efcc11",
"omi_name": "packer-test-{{timestamp}}",
"omi_virtualization_type": "hvm",
"device_path": "/dev/xvdf",
"mount_partition": "0"
}],
"provisioners": [
{
"type": "shell",
"inline": [
"echo Packer-test | tee /tmp/test.txt"
]
}
]
}]
}
`