Sha256: 3ceb354392c990ee733b31140b68e51aa585fefc7632b7fd3e44b7cedda57b8a

Contents?: true

Size: 619 Bytes

Versions: 2

Compression:

Stored size: 619 Bytes

Contents

describe 'SexpStringifier' do
  before :each do
    @stub_unifier = double 'Unifier'
    @stub_ruby2ruby = double 'Ruby2Ruby'
    @stringifier = VirtualKeywords::SexpStringifier.new(
        @stub_unifier, @stub_ruby2ruby)
  end

  it 'stringifies sexps using unifier and ruby2ruby' do
    sexp = :fake_sexp
    unifier_result = :unified
    final_result = :final
    @stub_unifier.should_receive(:process).with(sexp).
        and_return unifier_result
    @stub_ruby2ruby.should_receive(:process).with(unifier_result).
        and_return final_result
    @stringifier.stringify(sexp).should eql final_result
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
virtual_keywords-0.3.1 lib/spec/sexp_stringifier_spec.rb
virtual_keywords-0.3.0 lib/spec/sexp_stringifier_spec.rb