HomePhorge

(maint) Fix destinations_spec failure on windows
ca313dce0c3eUnpublished

Unpublished Commit ยท Learn More

Repository Importing: This repository is still importing.

Description

(maint) Fix destinations_spec failure on windows

The CI spec tests for Puppet 2.7.x on windows are failing. This is bad.

The reason they're failing is because we recently patched Puppet 2.7.x
to add a new feature, Puppet.features.ansicolor? If this feature is
true then Puppet will output with ANSI colors. If false, bare strings
are sent.

The existing destinations_spec test wasn't updated to reflect this new
feature. The existing spec test assumes ANSI sequences will always be
sent if Puppet[:color] = true, but this is no longer the case because we
only send ANSI sequences if Puppet[:color] = true and
Puppet.features.ansicolor? is truthy.

This patch fixes the problem by stubbing Puppet.features.ansicolor? to
be true, matching up the spec expectation to the behavior of the system.

Details

Event Timeline

Jeff McCune <jeff@puppetlabs.com> committed rPUca313dce0c3e: (maint) Fix destinations_spec failure on windows (authored by Jeff McCune <jeff@puppetlabs.com>).Apr 26 2012, 2:55 AM