added test for doPublish() and doUnpublish()