MCPcopy Create free account
hub / github.com/imgproxy/imgproxy / String

Method String

processing/extend_test.go:55–73  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

53}
54
55func (e extendTestCase) String() string {
56 var b strings.Builder
57
58 fmt.Fprintf(&b, "extend_%dx%d", e.size.width, e.size.height)
59
60 if e.gravity != 0 {
61 fmt.Fprintf(&b, "_gravity_%s", e.gravity.String())
62 }
63
64 if e.xOffset != 0 || e.yOffset != 0 {
65 fmt.Fprintf(&b, "_offset_%f_%f", e.xOffset, e.yOffset)
66 }
67
68 if e.dpr > 0 {
69 fmt.Fprintf(&b, "_dpr_%g", e.dpr)
70 }
71
72 return b.String()
73}
74
75type extendArTestCase struct {
76 gravity processing.GravityType

Callers 3

StringMethod · 0.45
TestExtendMethod · 0.45
TestExtendAspectRatioMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected