|
|
@ -36,7 +36,6 @@ func TestHCLBasic(t *testing.T) {
|
|
|
|
|
|
|
|
|
|
|
|
target "webapp-plus" {
|
|
|
|
target "webapp-plus" {
|
|
|
|
inherits = ["webapp", "cross"]
|
|
|
|
inherits = ["webapp", "cross"]
|
|
|
|
network = "host"
|
|
|
|
|
|
|
|
args = {
|
|
|
|
args = {
|
|
|
|
IAMCROSS = "true"
|
|
|
|
IAMCROSS = "true"
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -64,7 +63,6 @@ func TestHCLBasic(t *testing.T) {
|
|
|
|
require.Equal(t, c.Targets[3].Name, "webapp-plus")
|
|
|
|
require.Equal(t, c.Targets[3].Name, "webapp-plus")
|
|
|
|
require.Equal(t, 1, len(c.Targets[3].Args))
|
|
|
|
require.Equal(t, 1, len(c.Targets[3].Args))
|
|
|
|
require.Equal(t, map[string]string{"IAMCROSS": "true"}, c.Targets[3].Args)
|
|
|
|
require.Equal(t, map[string]string{"IAMCROSS": "true"}, c.Targets[3].Args)
|
|
|
|
require.Equal(t, "host", *c.Targets[3].NetworkMode)
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
func TestHCLBasicInJSON(t *testing.T) {
|
|
|
|
func TestHCLBasicInJSON(t *testing.T) {
|
|
|
@ -95,7 +93,6 @@ func TestHCLBasicInJSON(t *testing.T) {
|
|
|
|
},
|
|
|
|
},
|
|
|
|
"webapp-plus": {
|
|
|
|
"webapp-plus": {
|
|
|
|
"inherits": ["webapp", "cross"],
|
|
|
|
"inherits": ["webapp", "cross"],
|
|
|
|
"network": "host",
|
|
|
|
|
|
|
|
"args": {
|
|
|
|
"args": {
|
|
|
|
"IAMCROSS": "true"
|
|
|
|
"IAMCROSS": "true"
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -126,7 +123,6 @@ func TestHCLBasicInJSON(t *testing.T) {
|
|
|
|
require.Equal(t, c.Targets[3].Name, "webapp-plus")
|
|
|
|
require.Equal(t, c.Targets[3].Name, "webapp-plus")
|
|
|
|
require.Equal(t, 1, len(c.Targets[3].Args))
|
|
|
|
require.Equal(t, 1, len(c.Targets[3].Args))
|
|
|
|
require.Equal(t, map[string]string{"IAMCROSS": "true"}, c.Targets[3].Args)
|
|
|
|
require.Equal(t, map[string]string{"IAMCROSS": "true"}, c.Targets[3].Args)
|
|
|
|
require.Equal(t, "host", *c.Targets[3].NetworkMode)
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
func TestHCLWithFunctions(t *testing.T) {
|
|
|
|
func TestHCLWithFunctions(t *testing.T) {
|
|
|
|