fix npe, update test
fix username in test