test: use T.TempDir
to create temporary test directory
#33082
+25
−59
Merged