@@ -288,12 +288,12 @@ def testUsageOutput(self):
288
288
component = tc .NoDefaults ()
289
289
t = trace .FireTrace (component , name = 'NoDefaults' )
290
290
usage_output = helptext .UsageText (component , trace = t , verbose = False )
291
- expected_output = '''
291
+ expected_output = """
292
292
Usage: NoDefaults <command>
293
293
available commands: double | triple
294
294
295
295
For detailed information on this command, run:
296
- NoDefaults --help'''
296
+ NoDefaults --help"""
297
297
298
298
self .assertEqual (
299
299
usage_output ,
@@ -303,12 +303,12 @@ def testUsageOutputVerbose(self):
303
303
component = tc .NoDefaults ()
304
304
t = trace .FireTrace (component , name = 'NoDefaults' )
305
305
usage_output = helptext .UsageText (component , trace = t , verbose = True )
306
- expected_output = '''
306
+ expected_output = """
307
307
Usage: NoDefaults <command>
308
308
available commands: double | triple
309
309
310
310
For detailed information on this command, run:
311
- NoDefaults --help'''
311
+ NoDefaults --help"""
312
312
self .assertEqual (
313
313
usage_output ,
314
314
textwrap .dedent (expected_output ).lstrip ('\n ' ))
@@ -318,11 +318,11 @@ def testUsageOutputMethod(self):
318
318
t = trace .FireTrace (component , name = 'NoDefaults' )
319
319
t .AddAccessedProperty (component , 'double' , ['double' ], None , None )
320
320
usage_output = helptext .UsageText (component , trace = t , verbose = False )
321
- expected_output = '''
321
+ expected_output = """
322
322
Usage: NoDefaults double COUNT
323
323
324
324
For detailed information on this command, run:
325
- NoDefaults double --help'''
325
+ NoDefaults double --help"""
326
326
self .assertEqual (
327
327
usage_output ,
328
328
textwrap .dedent (expected_output ).lstrip ('\n ' ))
@@ -331,12 +331,12 @@ def testUsageOutputFunctionWithHelp(self):
331
331
component = tc .function_with_help
332
332
t = trace .FireTrace (component , name = 'function_with_help' )
333
333
usage_output = helptext .UsageText (component , trace = t , verbose = False )
334
- expected_output = '''
334
+ expected_output = """
335
335
Usage: function_with_help <flags>
336
336
optional flags: --help
337
337
338
338
For detailed information on this command, run:
339
- function_with_help -- --help'''
339
+ function_with_help -- --help"""
340
340
self .assertEqual (
341
341
usage_output ,
342
342
textwrap .dedent (expected_output ).lstrip ('\n ' ))
@@ -345,12 +345,12 @@ def testUsageOutputFunctionWithDocstring(self):
345
345
component = tc .multiplier_with_docstring
346
346
t = trace .FireTrace (component , name = 'multiplier_with_docstring' )
347
347
usage_output = helptext .UsageText (component , trace = t , verbose = False )
348
- expected_output = '''
348
+ expected_output = """
349
349
Usage: multiplier_with_docstring NUM <flags>
350
350
optional flags: --rate
351
351
352
352
For detailed information on this command, run:
353
- multiplier_with_docstring --help'''
353
+ multiplier_with_docstring --help"""
354
354
self .assertEqual (
355
355
textwrap .dedent (expected_output ).lstrip ('\n ' ),
356
356
usage_output )
@@ -361,13 +361,13 @@ def testUsageOutputCallable(self):
361
361
t = trace .FireTrace (component , name = 'CallableWithKeywordArgument' ,
362
362
separator = '@' )
363
363
usage_output = helptext .UsageText (component , trace = t , verbose = False )
364
- expected_output = '''
364
+ expected_output = """
365
365
Usage: CallableWithKeywordArgument <command> | <flags>
366
366
available commands: print_msg
367
367
flags are accepted
368
368
369
369
For detailed information on this command, run:
370
- CallableWithKeywordArgument -- --help'''
370
+ CallableWithKeywordArgument -- --help"""
371
371
self .assertEqual (
372
372
textwrap .dedent (expected_output ).lstrip ('\n ' ),
373
373
usage_output )
@@ -376,11 +376,11 @@ def testUsageOutputConstructorWithParameter(self):
376
376
component = tc .InstanceVars
377
377
t = trace .FireTrace (component , name = 'InstanceVars' )
378
378
usage_output = helptext .UsageText (component , trace = t , verbose = False )
379
- expected_output = '''
379
+ expected_output = """
380
380
Usage: InstanceVars --arg1=ARG1 --arg2=ARG2
381
381
382
382
For detailed information on this command, run:
383
- InstanceVars --help'''
383
+ InstanceVars --help"""
384
384
self .assertEqual (
385
385
textwrap .dedent (expected_output ).lstrip ('\n ' ),
386
386
usage_output )
@@ -389,12 +389,12 @@ def testUsageOutputConstructorWithParameterVerbose(self):
389
389
component = tc .InstanceVars
390
390
t = trace .FireTrace (component , name = 'InstanceVars' )
391
391
usage_output = helptext .UsageText (component , trace = t , verbose = True )
392
- expected_output = '''
392
+ expected_output = """
393
393
Usage: InstanceVars <command> | --arg1=ARG1 --arg2=ARG2
394
394
available commands: run
395
395
396
396
For detailed information on this command, run:
397
- InstanceVars --help'''
397
+ InstanceVars --help"""
398
398
self .assertEqual (
399
399
textwrap .dedent (expected_output ).lstrip ('\n ' ),
400
400
usage_output )
@@ -403,11 +403,11 @@ def testUsageOutputEmptyDict(self):
403
403
component = {}
404
404
t = trace .FireTrace (component , name = 'EmptyDict' )
405
405
usage_output = helptext .UsageText (component , trace = t , verbose = True )
406
- expected_output = '''
406
+ expected_output = """
407
407
Usage: EmptyDict
408
408
409
409
For detailed information on this command, run:
410
- EmptyDict --help'''
410
+ EmptyDict --help"""
411
411
self .assertEqual (
412
412
textwrap .dedent (expected_output ).lstrip ('\n ' ),
413
413
usage_output )
@@ -416,11 +416,11 @@ def testUsageOutputNone(self):
416
416
component = None
417
417
t = trace .FireTrace (component , name = 'None' )
418
418
usage_output = helptext .UsageText (component , trace = t , verbose = True )
419
- expected_output = '''
419
+ expected_output = """
420
420
Usage: None
421
421
422
422
For detailed information on this command, run:
423
- None --help'''
423
+ None --help"""
424
424
self .assertEqual (
425
425
textwrap .dedent (expected_output ).lstrip ('\n ' ),
426
426
usage_output )
0 commit comments