test/angelo/eventsource_spec.rb in angelo-0.1.24 vs test/angelo/eventsource_spec.rb in angelo-0.2.0

- old
+ new

@@ -7,21 +7,21 @@ describe 'basics' do define_app do eventsource '/msg' do |c| - c.write sse_message 'hi' + c.message 'hi' c.close end eventsource '/event' do |c| - c.write sse_event :sse, 'bye' + c.event :sse, 'bye' c.close end eventsource '/headers', foo: 'bar' do |c| - c.write sse_event :sse, 'headers' + c.event :sse, 'headers' c.close end end @@ -57,15 +57,15 @@ before '/other' do raise Angelo::RequestError.new sse_message('foo'), 200 end eventsource '/msg' do |c| - c.write sse_message 'hi' + c.message 'hi' c.close end eventsource '/other' do |c| - c.write sse_message 'other' + c.message 'other' c.close end end