Sha256: 9d1bbcd6f085b4aefa8a4d2e09cf6eb22080d0ef1667b08403cfe7f750122ff4

Contents?: true

Size: 892 Bytes

Versions: 8

Compression:

Stored size: 892 Bytes

Contents

require 'qcmd'
require 'osc-ruby'

describe Qcmd::Commands do
  describe 'cue commands' do
    before do
      Qcmd.context = Qcmd::Context.new
      Qcmd.context.machine = Qcmd::Machine.new('machine', '1.1.1.1', 1000)
      Qcmd.context.workspace_connected = true
    end

    describe 'cue command always needing reply' do
      before do
        @address = '/workspace/TEST/cue/1/isRunning'
      end

      describe 'with args' do
        before do
          @message = OSC::Message.new(@address, 123)
        end

        it 'is detected' do
          Qcmd::Commands.expects_reply?(@message).should eql(true)
        end
      end

      describe 'without args' do
        before do
          @message = OSC::Message.new(@address, *@args)
        end

        it 'is detected' do
          Qcmd::Commands.expects_reply?(@message).should eql(true)
        end
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
qcmd-0.1.7 spec/unit/commands_spec.rb
qcmd-0.1.6 spec/commands_spec.rb
qcmd-0.1.5 spec/commands_spec.rb
qcmd-0.1.4 spec/commands_spec.rb
qcmd-0.1.3 spec/commands_spec.rb
qcmd-0.1.2 spec/commands_spec.rb
qcmd-0.1.1 spec/commands_spec.rb
qcmd-0.1.0 spec/commands_spec.rb