mirror of
https://github.com/gotenberg/gotenberg.git
synced 2026-08-15 03:42:15 +01:00
feat(pdfengines): apply multiple stamps and watermarks on every route
This commit is contained in:
@@ -1880,3 +1880,18 @@ func TestFormData_Stamps(t *testing.T) {
|
||||
t.Errorf("expected nil when no stamp file was uploaded, got %+v", none)
|
||||
}
|
||||
}
|
||||
|
||||
func TestFormData_Watermarks(t *testing.T) {
|
||||
form := &FormData{
|
||||
filesByField: map[string][]string{
|
||||
WatermarkFormField: {"/tmp/abc/a.png"},
|
||||
},
|
||||
}
|
||||
|
||||
var got []string
|
||||
form.Watermarks(&got)
|
||||
|
||||
if want := []string{"/tmp/abc/a.png"}; !reflect.DeepEqual(got, want) {
|
||||
t.Errorf("expected %+v, got %+v", want, got)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user