remove topic getter from TestPublisher and add missing end