test: use T.TempDir
to create temporary test directory
#33082
Merged
T.TempDir
to create temporary test directory
#33082