diff --git a/scenario.go b/scenario.go index dfa1712..b6b1c88 100644 --- a/scenario.go +++ b/scenario.go @@ -264,6 +264,15 @@ func doScenario(in *doScenarioInput) error { req = req.WithQuery(k, nv) } + if len(run.HTTP.Files) > 0 { + req = req.WithMultipart() + } + for k, v := range run.HTTP.Files { + fn := fmt.Sprintf("%v_files.%v", prefix, k) + nv, _ := s.ParseValue(v, fn) + req = req.WithFile(k, nv) + } + for k, v := range run.HTTP.Forms { fn := fmt.Sprintf("%v_forms.%v", prefix, k) nv, _ := s.ParseValue(v, fn)