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

pulibrary / orangelight / 945dd592-0499-4eb8-9049-14b44f80dff0

24 Jul 2025 03:43PM UTC coverage: 95.167% (-0.2%) from 95.407%
945dd592-0499-4eb8-9049-14b44f80dff0

Pull #5051

circleci

Ryan Jensen
Fix alignment of availability cards and change media query breakpoint for vertical card display
Pull Request #5051: 5033 adjust search

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✔
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✔
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'
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✔
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