fixed tests, minor changes in BateryWidget class