Method
getIntParameter
(name string, defaultValue int, parameters []plugin.ExecutionParameter)
Source from the content-addressed store, hash-verified
| 348 | } |
| 349 | |
| 350 | func (c TestRunCommand) getIntParameter(name string, defaultValue int, parameters []plugin.ExecutionParameter) int { |
| 351 | result := defaultValue |
| 352 | for _, p := range parameters { |
| 353 | if p.Name == name { |
| 354 | if data, ok := p.Value.(int); ok { |
| 355 | result = data |
| 356 | break |
| 357 | } |
| 358 | } |
| 359 | } |
| 360 | return result |
| 361 | } |
| 362 | |
| 363 | func (c TestRunCommand) getBoolParameter(name string, defaultValue bool, parameters []plugin.ExecutionParameter) bool { |
| 364 | result := defaultValue |
Tested by
no test coverage detected