Bug #1244

User type RSpec tests fail as non-root

Added by Marcin Owsiany over 3 years ago. Updated over 3 years ago.

Status:Rejected Start date:
Priority:Normal Due date:
Assignee:Puppet Community % Done:

0%

Category:testing
Target version:-
Affected Puppet version:0.24.4 Branch:
Keywords:
Votes: 0

Description

This is on Debian etch. Running the rspec tests in master branch as a regular user produces:

1)
Puppet::DevError in 'Puppet::Type::User should have a default provider inheriting from Puppet::Provider'
Could not find a default provider for user
/home/porridge/Desktop/coding/puppet-git/lib/puppet/metatype/providers.rb:39:in @defaultprovider'
/home/porridge/Desktop/coding/puppet-git/spec/unit/type/user.rb:36:
/home/porridge/Desktop/coding/puppet-git/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:19:in @run'
/home/porridge/Desktop/coding/puppet-git/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:17:in @each'
/home/porridge/Desktop/coding/puppet-git/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:17:in @run'
integration/reports.rb:10:

2)
'Puppet::Type::User should be able to create a instance' FAILED
expected no Exception, got #
/home/porridge/Desktop/coding/puppet-git/spec/unit/type/user.rb:8:in @mkuser'
/home/porridge/Desktop/coding/puppet-git/spec/unit/type/user.rb:40:
/home/porridge/Desktop/coding/puppet-git/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:19:in @run'
/home/porridge/Desktop/coding/puppet-git/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:17:in @each'
/home/porridge/Desktop/coding/puppet-git/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:17:in @run'
integration/reports.rb:10:

3)
'Puppet::Type::User instances should have a valid provider' FAILED
expected no Exception, got #
/home/porridge/Desktop/coding/puppet-git/spec/unit/type/user.rb:8:in @mkuser'
/home/porridge/Desktop/coding/puppet-git/spec/unit/type/user.rb:49:
/home/porridge/Desktop/coding/puppet-git/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:19:in @run'
/home/porridge/Desktop/coding/puppet-git/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:17:in @each'
/home/porridge/Desktop/coding/puppet-git/spec/monkey_patches/add_confine_and_runnable_to_rspec_dsl.rb:17:in @run'
integration/reports.rb:10:

This is probably because only usable provider on this platform uses tools which are outside non-root users path. However even if the tools were available, creating the user would fail with insufficient permissions.

Out of curiosity: what makes sure the test user disappears after the test finishes?


Related issues

related to Puppet - Bug #1631: Puppet's path should always include '/usr/sbin' and '/sbin' Closed 10/06/2008

History

Updated by Marcin Owsiany over 3 years ago

I found some more, all failing with “Could not find a default provider for user”:

Puppet::DevError in 'Puppet::TransBucket when generating a catalog should set each [[TransBucket]]'s catalog before converting to a RAL resource'
Puppet::DevError in 'Puppet::TransBucket when generating a catalog should set each [[TransObject]]'s catalog before converting to a RAL resource'
Puppet::DevError in 'Puppet::TransBucket when generating a catalog should only call to_type on each resource once'
Puppet::DevError in 'Puppet::TransBucket when generating a catalog should finalize all resources'
Puppet::DevError in 'Puppet::TransBucket when generating a catalog should add all resources to the graph's resource table'
Puppet::DevError in 'Puppet::TransBucket when generating a catalog should convert all transportable buckets to RAL components'
Puppet::DevError in 'Puppet::TransBucket when generating a catalog should convert all transportable objects to RAL resources'

Updated by Redmine Admin over 3 years ago

  • Status changed from 1 to Accepted

Updated by Luke Kanies over 3 years ago

  • Status changed from Accepted to Rejected
  • Affected Puppet version set to 0.24.4

I’m closing this in favor of #1631, since it discusses the actual problem.

Also available in: Atom PDF