fixed a bug and cleaned up in test map