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

     1  package testkube
     2  
     3  import (
     4  	"strconv"
     5  )
     6  
     7  type Artifacts []Artifact
     8  
     9  func (artifacts Artifacts) Table() (header []string, output [][]string) {
    10  	header = []string{"Execution", "Name", "Size (KB)"}
    11  	for _, e := range artifacts {
    12  		output = append(output, []string{
    13  			e.ExecutionName,
    14  			e.Name,
    15  			strconv.FormatInt(int64(e.Size), 10),
    16  		})
    17  	}
    18  
    19  	return
    20  }