Sha256: 325156a1aabc2d5e39259aeb05bb769a763fdf0b6a455ed257f35ed8ad812a4b

Contents?: true

Size: 418 Bytes

Versions: 12

Compression:

Stored size: 418 Bytes

Contents

require 'rubygems'
require 'test/unit'

require File.dirname(__FILE__) + "/../lib/mailbox"

class Logger
  include Mailbox

  mailslot
  def log(message)
    p "Logging on Thread #{Thread.current.object_id} - #{message}"
  end
end

class LogExample < Test::Unit::TestCase

  def test_log_example
    logger = Logger.new
    p "Current Thread is #{Thread.current.object_id}"
    logger.log "some log message"
  end

end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
mailbox-0.2.7 example/log_example.rb
mailbox-0.2.6 example/log_example.rb
mailbox-0.2.5 example/log_example.rb
mailbox-0.2.4 example/log_example.rb
mailbox-0.2.3 example/log_example.rb
mailbox-0.2.2 example/log_example.rb
mailbox-0.2.1 example/log_example.rb
mailbox-0.2.0 example/log_example.rb
mailbox-0.1.7 example/log_example.rb
mailbox-0.1.6 example/log_example.rb
mailbox-0.1.4 example/log_example.rb
mailbox-0.1.3 example/log_example.rb