(xtb: string)
| 16 | const serializer = new Xtb(); |
| 17 | |
| 18 | function loadAsMap(xtb: string): {[id: string]: string} { |
| 19 | const {i18nNodesByMsgId} = serializer.load(xtb, 'url'); |
| 20 | const msgMap: {[id: string]: string} = {}; |
| 21 | Object.keys(i18nNodesByMsgId).forEach((id) => { |
| 22 | msgMap[id] = serializeNodes(i18nNodesByMsgId[id]).join(''); |
| 23 | }); |
| 24 | return msgMap; |
| 25 | } |
| 26 | |
| 27 | describe('load', () => { |
| 28 | it('should load XTB files with a doctype', () => { |
no test coverage detected
searching dependent graphs…