Bug #918
tests fail on debian without hddtemp service
| Status: | Closed | Start date: | ||
|---|---|---|---|---|
| Priority: | Low | Due date: | ||
| Assignee: | % Done: | 0% |
||
| Category: | - | |||
| Target version: | 0.24.0 | |||
| Affected Puppet version: | 0.25.4 | Branch: | ||
| Keywords: | ||||
| Votes: | 0 |
Description
Please apply the little patch in the tests/fix-service-tests-on-debian branch of my repo at git://git.black.co.at/puppet-bugfixes to fix the following three test failures when the hddtemp service is not installed on Debian:
1) Failure:
test_serviceenableandrun(TestLocalService)
[./ral/providers/service.rb:222:in @test_serviceenableandrun'
./ral/providers/service.rb:192:in @each'
./ral/providers/service.rb:192:in @test_serviceenableandrun'
/tests/puppet-trunk/test/lib/mocha/test_case_adapter.rb:19:in @+send+'
/tests/puppet-trunk/test/lib/mocha/test_case_adapter.rb:19:in @run']:
Service did not sync both properties.
is not true.
2) Failure:
test_serviceenabledisable(TestLocalService)
[./ral/providers/service.rb:123:in @cycleenable'
./ral/providers/service.rb:121:in @each'
./ral/providers/service.rb:121:in @cycleenable'
./ral/providers/service.rb:183:in @test_serviceenabledisable'
./ral/providers/service.rb:176:in @each'
./ral/providers/service.rb:176:in @test_serviceenabledisable'
/tests/puppet-trunk/test/lib/mocha/test_case_adapter.rb:19:in @+send+'
/tests/puppet-trunk/test/lib/mocha/test_case_adapter.rb:19:in @run']:
Service hddtemp is not enabled.
<:false> expected but was
<:true>.
3) Failure:
test_servicestartstop(TestLocalService)
[./ral/providers/service.rb:72:in @cycleservice'
./ral/providers/service.rb:70:in @each'
./ral/providers/service.rb:70:in @cycleservice'
./ral/providers/service.rb:167:in @test_servicestartstop'
./ral/providers/service.rb:162:in @each'
./ral/providers/service.rb:162:in @test_servicestartstop'
/tests/puppet-trunk/test/lib/mocha/test_case_adapter.rb:19:in @+send+'
/tests/puppet-trunk/test/lib/mocha/test_case_adapter.rb:19:in @run']:
Service hddtemp is not running.
<:running> expected but was
<:stopped>.
The patch replaces the usage of hddtemp with sysklogd which is installed on etch and later with the minimal system. Of course the proper fix would be to move the tests to spec and stub out the various calls to the system.
History
Updated by Luke Kanies over 4 years ago
- Status changed from 1 to Closed
- 7 set to fixed
Fixed in commit:dedc56a6ae583daca304c053b1be8a52bcdbd13a.