File: buffer_unpacker.rb

package info (click to toggle)
ruby-msgpack 1.0.0-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 844 kB
  • ctags: 1,033
  • sloc: ansic: 4,022; ruby: 3,378; java: 1,727; sh: 45; makefile: 2
file content (19 lines) | stat: -rw-r--r-- 337 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
# encoding: ascii-8bit
require 'spec/spec_helper'

describe Unpacker do
  let :unpacker do
    Unpacker.new
  end

  let :packer do
    Packer.new
  end

  it 'buffer' do
    o1 = unpacker.buffer.object_id
    unpacker.buffer << 'frsyuki'
    unpacker.buffer.to_s.should == 'frsyuki'
    unpacker.buffer.object_id.should == o1
  end
end