(t *testing.T)
| 827 | } |
| 828 | |
| 829 | func TestPathToPS(t *testing.T) { |
| 830 | var tts = []struct { |
| 831 | p string |
| 832 | ps string |
| 833 | }{ |
| 834 | {"", ""}, |
| 835 | {"L10 0Q15 10 20 0M20 10C20 20 30 20 30 10z", "0 0 moveto 10 0 lineto 13.333333 6.6666667 16.666667 6.6666667 20 0 curveto 20 10 moveto 20 20 30 20 30 10 curveto closepath"}, |
| 836 | {"L10 0M20 0L30 0", "0 0 moveto 10 0 lineto 20 0 moveto 30 0 lineto"}, |
| 837 | {"A5 5 0 0 1 10 0", "0 0 moveto 5 0 5 5 180 360 0 ellipse"}, |
| 838 | {"A10 5 90 0 0 10 0", "0 0 moveto 5 0 10 5 90 -90 90 ellipsen"}, |
| 839 | } |
| 840 | for _, tt := range tts { |
| 841 | t.Run(tt.p, func(t *testing.T) { |
| 842 | test.T(t, MustParseSVGPath(tt.p).ToPS(), tt.ps) |
| 843 | }) |
| 844 | } |
| 845 | } |
| 846 | |
| 847 | func TestPathToPDF(t *testing.T) { |
| 848 | var tts = []struct { |
nothing calls this directly
no test coverage detected