Error fix and improve performance at tests

Reuse wallet at rounding tests and fix a ReferenceError.