Sha256: 0bffc6a4298848edb75453401fbdb96286f1c3726927598a36c3d9637020f76d

Contents?: true

Size: 748 Bytes

Versions: 1

Compression:

Stored size: 748 Bytes

Contents

require 'spec_helper'

describe Mail::Encodings::QuotedPrintable do
  
  it "should encode quoted printable from text" do
    result = "This is a test=\r\n"
    Mail::Encodings::QuotedPrintable.encode('This is a test').should == result
  end
  
  it "should decode quoted printable" do
    result = "This is a test"
    Mail::Encodings::QuotedPrintable.decode("This is a test").should == result
  end
  
  it "should encode quoted printable from binary" do
    result = "=00=00=00=00=\r\n"
    Mail::Encodings::QuotedPrintable.encode("\000\000\000\000").should == result
  end
  
  it "should decode quoted printable text" do
    result = "\000\000\000\000"
    Mail::Encodings::QuotedPrintable.decode("=00=00=00=00").should == result
  end
  
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
rack-mail_exception-0.0.1 vendor/mail/spec/mail/encodings/quoted_printable_spec.rb