Sha256: b9e1f8a1a9594f0bfd6ba7232bd38784692c5f116862f33d394ff7326d1002d9

Contents?: true

Size: 372 Bytes

Versions: 52

Compression:

Stored size: 372 Bytes

Contents

# frozen_string_literal: true

module HL7Helpers
  def hl7_message_from_file(filename, patient)
    result = parse_hl7_file(filename, patient)
    Renalware::Feeds::HL7Message.new(::HL7::Message.new(result.lines))
  end

  def parse_hl7_file(filename, patient, pid = nil)
    body = file_fixture("hl7/#{filename}.hl7.erb").read
    ERB.new(body).result(binding)
  end
end

Version data entries

52 entries across 52 versions & 1 rubygems

Version Path
renalware-core-2.1.1 spec/support/hl7_helpers.rb
renalware-core-2.1.0 spec/support/hl7_helpers.rb
renalware-core-2.0.167 spec/support/hl7_helpers.rb
renalware-core-2.0.166 spec/support/hl7_helpers.rb
renalware-core-2.0.165 spec/support/hl7_helpers.rb
renalware-core-2.0.164 spec/support/hl7_helpers.rb
renalware-core-2.0.163 spec/support/hl7_helpers.rb
renalware-core-2.0.162 spec/support/hl7_helpers.rb
renalware-core-2.0.161 spec/support/hl7_helpers.rb
renalware-core-2.0.160 spec/support/hl7_helpers.rb
renalware-core-2.0.159 spec/support/hl7_helpers.rb
renalware-core-2.0.158 spec/support/hl7_helpers.rb
renalware-core-2.0.157 spec/support/hl7_helpers.rb
renalware-core-2.0.156 spec/support/hl7_helpers.rb
renalware-core-2.0.155 spec/support/hl7_helpers.rb
renalware-core-2.0.153 spec/support/hl7_helpers.rb
renalware-core-2.0.152 spec/support/hl7_helpers.rb
renalware-core-2.0.151 spec/support/hl7_helpers.rb
renalware-core-2.0.149 spec/support/hl7_helpers.rb
renalware-core-2.0.148 spec/support/hl7_helpers.rb