test/propono_test.rb in propono-0.9.1 vs test/propono_test.rb in propono-0.10.0
- old
+ new
@@ -7,9 +7,18 @@
topic, message = "Foo", "Bar"
Publisher.expects(:publish).with(topic, message, {})
Propono.publish(topic, message)
end
+ def test_publish_sets_suffix_publish
+ Propono.config.queue_suffix = "-bar"
+ topic = "foo"
+ Publisher.expects(:publish).with("foo-bar", '', {})
+ Propono.publish(topic, "")
+ ensure
+ Propono.config.queue_suffix = ""
+ end
+
def test_subscribe_by_queue_calls_subscribe
topic = 'foobar'
Subscriber.expects(:subscribe_by_queue).with(topic)
Propono.subscribe_by_queue(topic)
end