Sha256: 3e82951c9edede6560bc5fb7f17081a99f1b0cebcd360e28ef3d9eda588928bd

Contents?: true

Size: 655 Bytes

Versions: 21

Compression:

Stored size: 655 Bytes

Contents

# !SLIDE :capture_code_output true
# One-way, named pipe service

$stderr.puts "  #{$$} at #{__FILE__}:#{__LINE__}"

require 'example_helper'
begin
  File.unlink(service_pipe = "service.pipe") rescue nil
  Email.asir.transport = t =
    ASIR::Transport::File.new(:file => service_pipe)
  t.encoder =
    ASIR::Coder::Yaml.new
  server_process do
    t.prepare_server!
    t.run_server!
  end
  pr Email.asir.send_email(:pdf_invoice, :to => "user@email.com", :customer => @customer)
ensure
  t.close; sleep 1; server_kill
end

# !SLIDE END
# EXPECT: : client process
# EXPECT: : server process
# EXPECT: : Email.send_mail :pdf_invoice
# EXPECT: : pr: nil

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
asir-1.2.1 example/ex06.rb
asir-1.2.0 example/ex06.rb
asir-1.1.12 example/ex06.rb
asir-1.1.11 example/ex06.rb
asir-1.1.10 example/ex06.rb
asir-1.1.9 example/ex06.rb
asir-1.1.8 example/ex06.rb
asir-1.1.7 example/ex06.rb
asir-1.1.6 example/ex06.rb
asir-1.1.5 example/ex06.rb
asir-1.1.4 example/ex06.rb
asir-1.1.3 example/ex06.rb
asir-1.1.2 example/ex06.rb
asir-1.1.1 example/ex06.rb
asir-1.1.0 example/ex06.rb
asir-1.0.8 example/ex06.rb
asir-1.0.7 example/ex06.rb
asir-1.0.6 example/ex06.rb
asir-1.0.5 example/ex06.rb
asir-1.0.4 example/ex06.rb