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

pulibrary / tigerdata-app / 88c82417-71e1-4f84-8337-7bf4bd1a5618

29 Jul 2025 08:15PM UTC coverage: 75.423% (-5.2%) from 80.666%
88c82417-71e1-4f84-8337-7bf4bd1a5618

Pull #1656

circleci

hectorcorrea
Marked a bunch of tests as integration since they create projects in Mediaflux
Pull Request #1656: Added error handling to the request to project workflow

12 of 17 new or added lines in 4 files covered. (70.59%)

157 existing lines in 19 files now uncovered.

2274 of 3015 relevant lines covered (75.42%)

344.11 hits per line

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

36.84
/app/models/mediaflux/accumulator_create_collection_request.rb
1
# frozen_string_literal: true
2
module Mediaflux
1✔
3
  class AccumulatorCreateCollectionRequest < Request
1✔
4
    attr_reader :namespace, :asset_name, :collection
1✔
5

6
    # Constructor
7
    # @param session_token [String] the API token for the authenticated session
8
    # @param collection [String] Id of the collection
9
    # @param name [String] Name of the Accumulator
10
    # @param type [String] type of the Accumulator
11
    #             "collection.asset.count"
12
    #              "content.all.copy.tag.size"
13
    #             "content.all.size"
14
    #              "content.all.store.size"
15
    #              "content.all.store.size.by.owner"
16
    #              "content.all.store.size.by.xpath"
17
    #              "content.all.type.size"
18
    def initialize(session_token:, collection:, name:, type:)
1✔
UNCOV
19
      super(session_token: session_token)
×
UNCOV
20
      @name = name
×
UNCOV
21
      @collection = collection
×
UNCOV
22
      @type = type
×
23
    end
24

25
    # Specifies the Mediaflux service to use when creating assets
26
    # @return [String]
27
    def self.service
1✔
UNCOV
28
      "asset.collection.accumulator.add"
×
29
    end
30

31
    private
1✔
32

33
      # The generated XML mimics what we get when we issue an Aterm command as follows:
34
      # > asset.collection.accumulator.add :id 3218 :cascade true
35
      #      :accumulator < :name mytest-01509-count :type collection.asset.count >
36
      #
37
      def build_http_request_body(name:)
1✔
UNCOV
38
        super do |xml|
×
UNCOV
39
          xml.args do
×
UNCOV
40
            xml.id @collection
×
UNCOV
41
            xml.cascade true
×
UNCOV
42
            xml.accumulator do
×
UNCOV
43
              xml.name @name
×
UNCOV
44
              xml.type @type
×
45
            end
46
          end
47
        end
48
      end
49
  end
50
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