2015-06-08 23:24:49 -04:00
|
|
|
package iso
|
|
|
|
|
|
|
|
import (
|
2019-12-12 04:43:51 -05:00
|
|
|
"io/ioutil"
|
|
|
|
"path/filepath"
|
2015-06-08 23:24:49 -04:00
|
|
|
"testing"
|
|
|
|
|
2017-04-04 16:39:01 -04:00
|
|
|
builderT "github.com/hashicorp/packer/helper/builder/testing"
|
2015-06-08 23:24:49 -04:00
|
|
|
)
|
|
|
|
|
|
|
|
func TestBuilderAcc_basic(t *testing.T) {
|
2019-12-12 04:43:51 -05:00
|
|
|
templatePath := filepath.Join("testdata", "minimal.json")
|
|
|
|
bytes, err := ioutil.ReadFile(templatePath)
|
|
|
|
if err != nil {
|
|
|
|
t.Fatalf("failed to load template file %s", templatePath)
|
|
|
|
}
|
|
|
|
|
2015-06-08 23:24:49 -04:00
|
|
|
builderT.Test(t, builderT.TestCase{
|
|
|
|
Builder: &Builder{},
|
2019-12-12 04:43:51 -05:00
|
|
|
Template: string(bytes),
|
2015-06-08 23:24:49 -04:00
|
|
|
})
|
|
|
|
}
|