// GetEnvVars returns environment variables for the test process.
GetEnvVars returns environment variables for the test process.
// GetEnvVars returns environment variables for the test process .
func (me *MockEntry) GetEnvVars() []string {
	if me == nil {
		return []string{"MOCK_EXEC_EXIT_CODE=0"}
	}
	var s []string
	if me.ExitCode != 0 {
		s = append(s, fmt.Sprintf("MOCK_EXEC_EXIT_CODE=%d", me.ExitCode))
	}
	if me.Sleep > 0 {
		s = append(s, fmt.Sprintf("MOCK_EXEC_SLEEP=%d", me.Sleep))
	}
	s = append(s, "MOCK_EXEC_OUTPUT="+me.Output)
	if len(me.Extra) > 0 {
		s = append(s, me.Extra...)
	}
	return s
}
func ( me * MockEntry ) GetEnvVars ( ) [ ] string { if me == nil { return [ ] string { " " } } var s [ ] string if me . ExitCode != 0 { s = append ( s , fmt . Sprintf ( " " , me . ExitCode ) ) } if me . Sleep > 0 { s = append ( s , fmt . Sprintf ( " " , me . Sleep ) ) } s = append ( s , " " + me . Output ) if len ( me . Extra ) > 0 { s = append ( s , me . Extra ... ) } return s }
GetEnvVars returns environment variables for the test process.
GetEnvVars returns environment variables for the test process .