code formatter

- delete variable for performance
fix UnitTest, cause deprecate method