test: fixed search failing on Travis CI

Added a small delay between `npm publish` and `npm search` to let Reggie
server process the published package. This is needed because Reggie returns
response before the processing was finished.
Fixed deletion of package

Modified deletePackage to remove the package entry when there were
no more versions present.
0.1.5