finished testing for datastructure and integrated with server class