Lines Matching full:expand
224 result = mc.Expand(input_str)
237 self.assertEqual(mc.Expand('bar(xYz)'), 'xYz- -xYz-xyz-XYz-XYZ')
238 self.assertEqual(mc.Expand('bar(MnoP)'), 'MnoP- -mnoP-mnop-MnoP-MNOP')
240 self.assertEqual(mc.Expand('bar()'), '-----')
269 result = mc.Expand(input_str)
301 self.assertEqual(mc.Expand('StartIt()'), expected)
313 result = mc.Expand('foo(A,B)')
337 # 5. One expand, one define (that runs to end of file)
338 ('a\n//%PDDM-EXPAND foo()\nbody\n//%PDDM-EXPAND-END\n'
341 # 6. One define ended with an expand.
343 '//%PDDM-EXPAND bar()\nbody2\n//%PDDM-EXPAND-END\n',
346 ('a\n//%PDDM-EXPAND foo(1)\nbody\n//%PDDM-EXPAND foo(2)\nbody2\n//%PDDM-EXPAND-END\n'
365 ('//%PDDM-EXPAND a()\n//%PDDM-BOGUS',
366 'Ran into directive ("//%PDDM-BOGUS", line 2) while in "//%PDDM-EXPAND a()".'),
367 ('//%PDDM-EXPAND a()\n//%PDDM-DEFINE a()\n//%body\n',
368 'Ran into directive ("//%PDDM-DEFINE", line 2) while in "//%PDDM-EXPAND a()".'),
370 ('//%PDDM-EXPAND a()\na\nb\n',
371 'Hit the end of the file while in "//%PDDM-EXPAND a()".'),
375 ('//%PDDM-DEFINE a()\n//%body\n//%PDDM-EXPAND-END a()',
376 'Ran into directive ("//%PDDM-EXPAND-END", line 3) while in "//%PDDM-DEFINE a()".'),
380 ('a\n//%PDDM-EXPAND-END a()\n//a\n',
381 'Unexpected line 2: "//%PDDM-EXPAND-END a()".'),
401 //%PDDM-EXPAND mumble(abc)
402 //%PDDM-EXPAND-END
404 //%PDDM-EXPAND mumble(def)
405 //%PDDM-EXPAND mumble(ghi)
406 //%PDDM-EXPAND-END
419 //%PDDM-EXPAND mumble(abc)
425 //%PDDM-EXPAND-END mumble(abc)
427 //%PDDM-EXPAND mumble(def)
433 //%PDDM-EXPAND mumble(ghi)
439 //%PDDM-EXPAND-END (2 expansions)
447 //%PDDM-EXPAND mumble(abc)
448 //%PDDM-EXPAND-END mumble(abc)
450 //%PDDM-EXPAND mumble(def)
451 //%PDDM-EXPAND mumble(ghi)
452 //%PDDM-EXPAND-END (2 expansions)
505 //%PDDM-EXPAND foobar(x_)
506 //%PDDM-EXPAND-END
513 self.fail('Should throw exception! Test failed to catch expand error.')
518 ' started:\n Line 5: //%PDDM-EXPAND foobar(x_)')