add publish_events rspec matcher and simplify publish_event

TODO: consolidate this logic?
bump version to 0.2.7