added tests and functionality to ship class