Unit tests done by sam