|
|
|
|
@ -29,6 +29,7 @@ func Test_console(t *testing.T) {
|
|
|
|
|
}{
|
|
|
|
|
{"help", []string{"console"}, nil, packer.ConsoleHelp + "\n"},
|
|
|
|
|
{"help", []string{"console", "--config-type=hcl2"}, nil, hcl2template.PackerConsoleHelp + "\n"},
|
|
|
|
|
{"help", []string{"console", "--config-type=hcl2", "--use-sequential-evaluation"}, nil, hcl2template.PackerConsoleHelp + "\n"},
|
|
|
|
|
{"var.fruit", []string{"console", filepath.Join(testFixture("var-arg"), "fruit_builder.pkr.hcl")}, []string{"PKR_VAR_fruit=potato"}, "potato\n"},
|
|
|
|
|
{"upper(var.fruit)", []string{"console", filepath.Join(testFixture("var-arg"), "fruit_builder.pkr.hcl")}, []string{"PKR_VAR_fruit=potato"}, "POTATO\n"},
|
|
|
|
|
{"1 + 5", []string{"console", "--config-type=hcl2"}, nil, "6\n"},
|
|
|
|
|
|