Project

General

Profile

Revision bf81b9cf

Added by Thomas McKay over 8 years ago

test-fixes - setup_test clean except for manifest upload repeat

View differences:

lib/hammer_cli_csv/products.rb
58 58
          @existing_products[line[ORGANIZATION]][product['name']] = product['id'] if product
59 59

  
60 60
          if product
61
            @api.resource(:repositorys).call(:index, {
61
            @api.resource(:repositories).call(:index, {
62 62
                                      'organization_id' => katello_organization(:name => line[ORGANIZATION]),
63 63
                                      'product_id' => product['id'],
64 64
                                      'enabled' => true,
......
83 83
                                               'name' => name
84 84
                                             })['id']
85 85
          @existing_products[line[ORGANIZATION]][name] = product_id
86
          print "done\n" if option_verbose?
86
        else
87
          # Nothing to update for products
88
          print "Updating product '#{name}'..." if option_verbose?
87 89
        end
90
        print "done\n" if option_verbose?
88 91
        @existing_repositories[line[ORGANIZATION] + name] ||= {}
89 92

  
90 93
        # Only creating repositories, not updating
91 94
        repository_name = namify(line[REPOSITORY], number)
92 95
        if !@existing_repositories[line[ORGANIZATION] + name][labelize(repository_name)]
93 96
          print "Creating repository '#{repository_name}' in product '#{name}'..." if option_verbose?
94
          @api.resource(:repositorys).call(:create, {
97
          @api.resource(:repositories).call(:create, {
95 98
                                     'organization_id' => katello_organization(:name => line[ORGANIZATION]),
96 99
                                     'name' => repository_name,
97 100
                                     'label' => labelize(repository_name),

Also available in: Unified diff