Sha256: cb31a3385db5650343d1e1cecab316939661b1157f121190c355ecb528708498

Contents?: true

Size: 676 Bytes

Versions: 3

Compression:

Stored size: 676 Bytes

Contents

require 'smilies/client'


module Smilies

  describe Client do

    before do
      @server = mock :server
      @client = Client.new(@server)
    end

    it 'should send a green message to server' do
      @server.should_receive(:green).with('green', 'Really green!')
      @client.green('green', 'Really green!')
    end

    it 'should send a yellow message to server' do
      @server.should_receive(:yellow).with('yellow', 'Really yellow!')
      @client.yellow('yellow', 'Really yellow!')
    end

    it 'should send a red message to server' do
      @server.should_receive(:red).with('red', 'Really red!')
      @client.red('red', 'Really red!')
    end

  end

end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
armin-joellenbeck-smilies-0.0.1 spec/smilies/client_spec.rb
armin-joellenbeck-smilies-0.0.2 spec/smilies/client_spec.rb
armin-joellenbeck-smilies-0.0.3 spec/smilies/client_spec.rb