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

pulibrary / pdc_discovery / 52de272a-147e-4678-aed6-fc56c3cd3458

07 Nov 2024 02:04PM UTC coverage: 97.15%. Remained the same
52de272a-147e-4678-aed6-fc56c3cd3458

push

circleci

jrgriffiniii
Addressing the failing tests for DSpace and DescribeIndexer

56 of 56 new or added lines in 5 files covered. (100.0%)

10 existing lines in 3 files now uncovered.

3579 of 3684 relevant lines covered (97.15%)

312.13 hits per line

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

78.05
/spec/models/version_footer_spec.rb
1
# frozen_string_literal: true
2

3
require 'rails_helper'
1✔
4

5
# rubocop:disable RSpec/ExampleLength
6
RSpec.describe VersionFooter do
1✔
7
  before do
1✔
8
    described_class.reset!
2✔
9
  end
10

11
  describe "info" do
1✔
12
    context "with stale information" do
1✔
13
      before do
1✔
14
        described_class.revision_file = Pathname.new(fixture_paths.first).join("REVISION").to_s
1✔
15
        described_class.revisions_logfile = Pathname.new(fixture_paths.first).join("revisions_stale.log").to_s
1✔
16
        described_class.reset!
1✔
17
      end
18

19
      it "detects stale information" do
1✔
20
        info = described_class.info
1✔
21
        expect(info[:stale]).to be true
1✔
22
        expect(info[:sha]).to eq "2222ae5c4ad9aaa0faad5208f1bf8108bd5934bf"
1✔
23
        expect(info[:branch]).to eq "version-2"
1✔
24
        expect(info[:version]).to eq "02 December 2021"
1✔
25
        expect(info[:tagged_release]).to be false
1✔
26
      end
27
    end
28

29
    context "with current information" do
1✔
30
      before do
1✔
31
        described_class.revision_file = Pathname.new(fixture_paths.first).join("REVISION").to_s
1✔
32
        described_class.revisions_logfile = Pathname.new(fixture_paths.first).join("revisions_current.log").to_s
1✔
33
        described_class.reset!
1✔
34
      end
35
      it "detects current information" do
1✔
36
        info = described_class.info
1✔
37
        expect(info[:stale]).to be false
1✔
38
        expect(info[:sha]).to eq "7a3b1d7c0f77db526963568ece3e0bb5a6399ce4"
1✔
39
        expect(info[:branch]).to eq "v0.8.0"
1✔
40
        expect(info[:version]).to eq "10 December 2021"
1✔
41
        expect(info[:tagged_release]).to be true
1✔
42
      end
43
    end
44

45
    context "with rollback information" do
1✔
46
      before do
1✔
UNCOV
47
        described_class.revision_file = Pathname.new(fixture_paths.first).join("REVISION").to_s
×
UNCOV
48
        described_class.revisions_logfile = Pathname.new(fixture_paths.first).join("revisions_rollback.log").to_s
×
UNCOV
49
        described_class.reset!
×
50
      end
51
      xit "detects current information" do
1✔
52
        info = described_class.info
×
53
        expect(info[:stale]).to be false # may want to reconsider what state stale should be
×
UNCOV
54
        expect(info[:sha]).to eq "to"
×
UNCOV
55
        expect(info[:branch]).to eq "rolled"
×
56
        expect(info[:version]).to eq "(Deployment date could not be parsed from: deploy rolled back to release 20211210150445\n.)"
×
57
        expect(info[:tagged_release]).to be false
×
58
      end
59
    end
60
  end
61
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