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

pulibrary / orangelight / 4e01fe00-694b-47b4-8b30-2de4dc4acc66

31 Jul 2025 07:56PM UTC coverage: 92.891% (-2.5%) from 95.4%
4e01fe00-694b-47b4-8b30-2de4dc4acc66

Pull #4962

circleci

web-flow
Merge pull request #5130 from pulibrary/clean_up_scss_comments

Remove SCSS commented code.
Pull Request #4962: Orangelight pos workcycle 07-07-2025

193 of 197 new or added lines in 24 files covered. (97.97%)

161 existing lines in 35 files now uncovered.

5932 of 6386 relevant lines covered (92.89%)

1443.08 hits per line

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

85.71
/app/models/oauth_token.rb
1
# frozen_string_literal: true
2

3
# This class is responsible for persisting
4
# OAuth tokens to the database
5
class OAuthToken < ApplicationRecord
2✔
6
  def token
2✔
7
    if expiration_time && not_yet_expired?
4✔
UNCOV
8
      self[:token]
×
9
    else
10
      fetch_new_token
4✔
11
      reload[:token]
4✔
12
    end
13
  end
14

15
    private
2✔
16

17
      def fetch_new_token
2✔
18
        service = OAuthService.new(service: self.service, endpoint:)
4✔
19
        self.token = service.new_token
4✔
20
        self.expiration_time = service.expiration_time
4✔
21
        save
4✔
22
      end
23

24
      def not_yet_expired?
2✔
UNCOV
25
        (Time.zone.now < expiration_time)
×
26
      end
27
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