MCPcopy
hub / github.com/tdewolff/minify / BenchmarkShortenPathData

Function BenchmarkShortenPathData

svg/pathdata_test.go:114–120  ·  view source on GitHub ↗
(b *testing.B)

Source from the content-addressed store, hash-verified

112////////////////////////////////////////////////////////////////
113
114func BenchmarkShortenPathData(b *testing.B) {
115 p := NewPathData(&Minifier{})
116 r := []byte("M8.64,223.948c0,0,143.468,3.431,185.777-181.808c2.673-11.702-1.23-20.154,1.316-33.146h16.287c0,0-3.14,17.248,1.095,30.848c21.392,68.692-4.179,242.343-204.227,196.59L8.64,223.948z")
117 for i := 0; i < b.N; i++ {
118 p.ShortenPathData(r)
119 }
120}

Callers

nothing calls this directly

Calls 2

ShortenPathDataMethod · 0.95
NewPathDataFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…