Sha256: e882ee72ac120e907388036c6366c62ecad39d4b68f3357dd25e427ca19e5f97
Contents?: true
Size: 639 Bytes
Versions: 5
Compression:
Stored size: 639 Bytes
Contents
#!/usr/bin/env ruby require File.expand_path(File.join(File.dirname(__FILE__), "spec_common")) require 'bindata/rest' describe BinData::Rest do it { should == "" } it "should read till end of stream" do data = "abcdefghij" subject.read(data).should == data end it "should allow setting value for completeness" do subject.assign("123") subject.should == "123" subject.to_binary_s.should == "123" end it "should accept BinData::BasePrimitive parameters" do rest = BinData::Rest.new(:check_value => "abc") lambda { rest.read("xyz") }.should raise_error(BinData::ValidityError) end end
Version data entries
5 entries across 5 versions & 1 rubygems
Version | Path |
---|---|
bindata-1.4.3 | spec/rest_spec.rb |
bindata-1.4.2 | spec/rest_spec.rb |
bindata-1.4.1 | spec/rest_spec.rb |
bindata-1.4.0 | spec/rest_spec.rb |
bindata-1.3.1 | spec/rest_spec.rb |