(string: string, spans: [number, number, string][])
| 17 | } |
| 18 | |
| 19 | function format(string: string, spans: [number, number, string][]) { |
| 20 | const s = S().appendString(string); |
| 21 | for (const span of spans) { |
| 22 | s.addSpan(...span); |
| 23 | } |
| 24 | return apply(s); |
| 25 | } |
| 26 | |
| 27 | test('no spans', () => { |
| 28 | expect(format('one two', [])).toEqual('one two'); |
no test coverage detected