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

pulibrary / orangelight / 6a53cc25-361b-48f8-88fe-5e399399943e

07 Mar 2025 08:45PM UTC coverage: 95.375% (-0.03%) from 95.4%
6a53cc25-361b-48f8-88fe-5e399399943e

Pull #3386

circleci

christinach
Use current_json from main
Pull Request #3386: Adds vocabulary column to subject table

8 of 10 new or added lines in 2 files covered. (80.0%)

8 existing lines in 2 files now uncovered.

6001 of 6292 relevant lines covered (95.38%)

1517.2 hits per line

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

88.89
/app/helpers/orangelight/browsables_helper.rb
1
# frozen_string_literal: true
2

3
module Orangelight
3✔
4
  module BrowsablesHelper
3✔
5
    def scsb_id?(bib_id)
3✔
6
      /^SCSB-\d+/ =~ bib_id
463✔
7
    end
8

9
    def bib_for_availability(bib_id)
3✔
10
      bib_id.to_i.to_s
455✔
11
    end
12

13
    def valid_bib_id?(bib_id)
3✔
14
      bib_for_availability(bib_id) == bib_id
223✔
15
    end
16

17
    def should_check_availability?(bib_id)
3✔
18
      !scsb_id?(bib_id) && valid_bib_id?(bib_id) && render_availability?
233✔
19
    end
20

21
    def current_browse_per_page
3✔
22
      params[:rpp].present? ? params[:rpp].to_i : 10
10✔
23
    end
24

25
    def vocab_type(vocab)
3✔
26
      if vocab == 'Library of Congress genre/form term'
50✔
NEW
27
        'lcgft_s'
×
28
      elsif vocab == 'Rare books genre term'
50✔
NEW
29
        'rbgenr_s'
×
30
      else
31
        'subject_facet'
50✔
32
      end
33
    end
34
  end
35
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