github.com/kubeshop/testkube@v1.17.23/pkg/api/v1/testkube/model_executor_extended.go (about)

     1  package testkube
     2  
     3  import "fmt"
     4  
     5  func (e *Executor) QuoteExecutorTextFields() {
     6  	if e.JobTemplate != "" {
     7  		e.JobTemplate = fmt.Sprintf("%q", e.JobTemplate)
     8  	}
     9  
    10  	for i := range e.Command {
    11  		if e.Command[i] != "" {
    12  			e.Command[i] = fmt.Sprintf("%q", e.Command[i])
    13  		}
    14  	}
    15  
    16  	for i := range e.Args {
    17  		if e.Args[i] != "" {
    18  			e.Args[i] = fmt.Sprintf("%q", e.Args[i])
    19  		}
    20  	}
    21  }