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

pulibrary / orangelight / 8635f6de-7d1b-4737-b521-3581575892dc

24 Jul 2025 07:37PM UTC coverage: 95.167% (-0.2%) from 95.407%
8635f6de-7d1b-4737-b521-3581575892dc

Pull #4962

circleci

web-flow
Center 'See X more locations' text in card (#5056)

Co-authored-by: Ryan Jensen <rj1044@princeton.edu>
Pull Request #4962: Orangelight pos workcycle 07-07-2025

140 of 143 new or added lines in 16 files covered. (97.9%)

16 existing lines in 5 files now uncovered.

6085 of 6394 relevant lines covered (95.17%)

1512.86 hits per line

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

60.0
/app/services/stackmap_location_factory.rb
1
# frozen_string_literal: true
2

3
class StackmapLocationFactory
3✔
4
  # Constructor
5
  # @param resolver_service [Class] API for the resolution service
6
  def initialize(resolver_service:)
3✔
UNCOV
7
    @resolver_service = resolver_service
×
8
  end
9

10
  # Checks to see if provided holding info should resolve to a stackmap url
11
  # @param call_number [String] the call number for the holding
12
  # @param library [String] the library in which the holding is located
13
  # @return [Boolean] Exclude stackmap url if return value is true
14
  def exclude?(call_number:, library:)
3✔
UNCOV
15
    excluded?(library) || call_number?(call_number, library)
×
16
  end
17

18
  private
3✔
19

20
    # Whether or not a library should exclude a holding from having its location resolved
21
    # @param library [String] the library in which the holding resides
22
    # @return [TrueClass, FalseClass]
23
    def excluded?(library)
3✔
24
      [
25
        'Fine Annex',
26
        'Forrestal Annex',
27
        'Mudd Manuscript Library',
28
        'Online',
29
        'Rare Books and Special Collections',
30
        'ReCAP',
31
        'Marquand Library'
UNCOV
32
      ].include?(library)
×
33
    end
34

35
    # Exclude the stackmap link for records without call numbers,
36
    # unless they are in Firestone (other locator works without a call number)
37
    def call_number?(call_number, library)
3✔
UNCOV
38
      call_number.nil? && library != 'Firestone Library'
×
39
    end
40
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