@@ -331,6 +331,37 @@ describe("Parser", () => {
331331 "b.Number" : "number=123" ,
332332 "b['Number']" : "number=123" ,
333333 "b[Number]" : "" ,
334+ "'str'.concat()" : "string=str" ,
335+ "'str'.concat('one')" : "string=strone" ,
336+ "'str'.concat('one').concat('two')" : "string=stronetwo" ,
337+ "'str'.concat('one').concat('two', 'three')" : "string=stronetwothree" ,
338+ "'str'.concat('one', 'two')" : "string=stronetwo" ,
339+ "'str'.concat('one', 'two').concat('three')" : "string=stronetwothree" ,
340+ "'str'.concat('one', 'two').concat('three', 'four')" : "string=stronetwothreefour" ,
341+ "'str'.concat('one', obj)" : "wrapped=['str' string=str]+[null]" ,
342+ "'str'.concat('one', obj).concat()" : "wrapped=['str' string=str]+[null]" ,
343+ "'str'.concat('one', obj, 'two')" : "wrapped=['str' string=str]+['two' string=two]" ,
344+ "'str'.concat('one', obj, 'two').concat()" : "wrapped=['str' string=str]+['two' string=two]" ,
345+ "'str'.concat('one', obj, 'two').concat('three')" : "wrapped=['str' string=str]+['three' string=three]" ,
346+ "'str'.concat(obj)" : "wrapped=['str' string=str]+[null]" ,
347+ "'str'.concat(obj).concat()" : "wrapped=['str' string=str]+[null]" ,
348+ "'str'.concat(obj).concat('one', 'two')" : "wrapped=['str' string=str]+['one', 'two' string=onetwo]" ,
349+ "'str'.concat(obj).concat(obj, 'one')" : "wrapped=['str' string=str]+['one' string=one]" ,
350+ "'str'.concat(obj).concat(obj, 'one', 'two')" : "wrapped=['str' string=str]+['one', 'two' string=onetwo]" ,
351+ "'str'.concat(obj).concat('one', obj, 'one')" : "wrapped=['str' string=str]+['one' string=one]" ,
352+ "'str'.concat(obj).concat('one', obj, 'two', 'three')" : "wrapped=['str' string=str]+['two', 'three' string=twothree]" ,
353+ "'str'.concat(obj, 'one')" : "wrapped=['str' string=str]+['one' string=one]" ,
354+ "'str'.concat(obj, 'one').concat()" : "wrapped=['str' string=str]+['one' string=one]" ,
355+ "'str'.concat(obj, 'one').concat('two', 'three')" : "wrapped=['str' string=str]+['two', 'three' string=twothree]" ,
356+ "'str'.concat(obj, 'one').concat(obj, 'two', 'three')" : "wrapped=['str' string=str]+['two', 'three' string=twothree]" ,
357+ "'str'.concat(obj, 'one').concat('two', obj, 'three')" : "wrapped=['str' string=str]+['three' string=three]" ,
358+ "'str'.concat(obj, 'one').concat('two', obj, 'three', 'four')" : "wrapped=['str' string=str]+['three', 'four' string=threefour]" ,
359+ "'str'.concat(obj, 'one', 'two')" : "wrapped=['str' string=str]+['one', 'two' string=onetwo]" ,
360+ "'str'.concat(obj, 'one', 'two').concat()" : "wrapped=['str' string=str]+['one', 'two' string=onetwo]" ,
361+ "'str'.concat(obj, 'one', 'two').concat('three', 'four')" : "wrapped=['str' string=str]+['three', 'four' string=threefour]" ,
362+ "'str'.concat(obj, 'one', 'two').concat(obj, 'three', 'four')" : "wrapped=['str' string=str]+['three', 'four' string=threefour]" ,
363+ "'str'.concat(obj, 'one', 'two').concat('three', obj, 'four')" : "wrapped=['str' string=str]+['four' string=four]" ,
364+ "'str'.concat(obj, 'one', 'two').concat('three', obj, 'four', 'five')" : "wrapped=['str' string=str]+['four', 'five' string=fourfive]" ,
334365 "`start${obj}mid${obj2}end`" : "template=[start string=start],[mid string=mid],[end string=end]" , // eslint-disable-line no-template-curly-in-string
335366 "`start${'str'}mid${obj2}end`" : "template=[start${'str'}mid string=startstrmid],[end string=end]" , // eslint-disable-line no-template-curly-in-string
336367 "'abc'.substr(1)" : "string=bc" ,
0 commit comments