Sha256: 73d4ab6346735894045f4841930f3acd78f5e5724cfc221ba4246cb5efdaf385

Contents?: true

Size: 729 Bytes

Versions: 9

Compression:

Stored size: 729 Bytes

Contents

# frozen_string_literal: true

require 'spec_helper'

describe RubyRabbitmqJanus::Janus::Messages::Message, type: :messages,
                                                      name: :message do
  let(:template) { 'base::info' }
  let(:msg_new) { described_class.new(template) }

  describe '#to_json' do
    let(:message) { msg_new.to_json }

    include_examples 'message is', String
  end

  describe '#to_hash' do
    let(:message) { msg_new.to_nice_json }

    include_examples 'message is', String
  end

  describe '#to_nice_json' do
    let(:message) { msg_new.to_hash }

    include_examples 'message is', Hash
  end

  describe '#correlation' do
    it { expect(msg_new.correlation).to be_kind_of(String) }
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
ruby_rabbitmq_janus-4.0.1 spec/ruby_rabbitmq_janus/janus/messages/message_spec.rb
ruby_rabbitmq_janus-4.0.1.pre.1265973744 spec/ruby_rabbitmq_janus/janus/messages/message_spec.rb
ruby_rabbitmq_janus-4.0.1.pre.1265506307 spec/ruby_rabbitmq_janus/janus/messages/message_spec.rb
ruby_rabbitmq_janus-4.0.1.pre.1265140558 spec/ruby_rabbitmq_janus/janus/messages/message_spec.rb
ruby_rabbitmq_janus-4.0.0 spec/ruby_rabbitmq_janus/janus/messages/message_spec.rb
ruby_rabbitmq_janus-4.0.0.pre.1001345090 spec/ruby_rabbitmq_janus/janus/messages/message_spec.rb
ruby_rabbitmq_janus-4.0.0.pre.1001181479 spec/ruby_rabbitmq_janus/janus/messages/message_spec.rb
ruby_rabbitmq_janus-4.0.0.pre.1001132533 spec/ruby_rabbitmq_janus/janus/messages/message_spec.rb
ruby_rabbitmq_janus-4.0.0.pre.1001107243 spec/ruby_rabbitmq_janus/janus/messages/message_spec.rb