• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

pulibrary / bibdata / b3c4a532-5da0-46f8-9c20-20018605a028

21 Mar 2025 08:11PM UTC coverage: 42.257% (-49.9%) from 92.185%
b3c4a532-5da0-46f8-9c20-20018605a028

push

circleci

sandbergja
Move various gems from the default Gemfile group to a more appropriate group

1599 of 3784 relevant lines covered (42.26%)

2.56 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

22.22
/marc_to_solr/lib/alma_reader.rb
1
# Alma MARC-XML files have no namespace defined, so we have to bypass that
2
# requirement in Nokogiri.
3
class AlmaReader < Traject::MarcReader
1✔
4
  def internal_reader
1✔
5
    @modified_internal_reader ||=
×
6
      begin
7
        result = super
×
8
        result.singleton_class.alias_method :old_start_element_namespace, :start_element_namespace
×
9
        # Redefine start_element_namespace to set the @ns to just be whatever
10
        # the URI is. For MARC records it's always the same anyways.
11
        result.singleton_class.define_method(:start_element_namespace) do |name, attributes = [], prefix = nil, uri = nil, ns = {}|
×
12
          @ns = uri
×
13
          old_start_element_namespace(name, attributes, prefix, uri, ns)
×
14
        end
15
        result
×
16
      end
17
  end
18
end
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc