MCPcopy Create free account
hub / github.com/devfile/api / addAttributes

Function addAttributes

test/v200/utils/common/command_test_utils.go:57–65  ·  view source on GitHub ↗

addAttributes creates returns a specifed number of attributes in a schema structure

(numAtrributes int)

Source from the content-addressed store, hash-verified

55
56// addAttributes creates returns a specifed number of attributes in a schema structure
57func addAttributes(numAtrributes int) map[string]string {
58 attributes := make(map[string]string)
59 for i := 0; i < numAtrributes; i++ {
60 AttributeName := "Name_" + GetRandomString(6, false)
61 attributes[AttributeName] = "Value_" + GetRandomString(6, false)
62 LogInfoMessage(fmt.Sprintf("Add attribute : %s = %s", AttributeName, attributes[AttributeName]))
63 }
64 return attributes
65}
66
67// addGroup creates and returns a group in a schema structure
68func (testDevFile *TestDevfile) addGroup() *schema.CommandGroup {

Callers

nothing calls this directly

Calls 2

GetRandomStringFunction · 0.85
LogInfoMessageFunction · 0.85

Tested by

no test coverage detected