Skip to content

Small test suite improvement #17687

Discussion options

You must be logged in to vote

So, I added this enhancement in

def TestAutoName():
# Static local vars holding values from previous use
if not hasattr(TestAutoName, '_autoNamePrefix'):
TestAutoName._autoNamePrefix = ''
TestAutoName._autoNameIndex = 0
callingFileName = inspect.stack()[1].filename
callingFuncName = inspect.stack()[1].function
callingFunc = globals()[callingFuncName]
if hasattr(callingFunc, '__doc__'):
callingFuncDoc = getattr(callingFunc, '__doc__')
else:
callingFuncDoc = callingFuncName
testNamePrefix = os.path.splitext(os.path.basename(callingFileName))[0]

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@brugger1
Comment options

@markcmiller86
Comment options

markcmiller86 Jun 2, 2022
Maintainer Author

@markcmiller86
Comment options

markcmiller86 Jun 2, 2022
Maintainer Author

Answer selected by markcmiller86
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants