From c7ef0d3068b6bfc3a6ce0cfe5f72b328c7bf9dda Mon Sep 17 00:00:00 2001 From: Michael Smith Date: Tue, 2 Aug 2016 22:41:09 -0700 Subject: [PATCH] (maint) Fix path for pxp-agent using new Windows MSI layout The Windows MSI layout changed to sharing binaries for C++ applications. That means pxp-agent.exe now relies on files in puppet/bin. Update the test to include that in PATH. For now hard-code in the test. It's not trivial to amend the privatebindir in config/aio/options.rb, since the setting is platform-dependent. This might eventually live in Beaker, but since it's only needed for this test that may not be worth it. [skip ci] --- acceptance/tests/pxp_agent_version.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/acceptance/tests/pxp_agent_version.rb b/acceptance/tests/pxp_agent_version.rb index f09bf29c..301de7d4 100644 --- a/acceptance/tests/pxp_agent_version.rb +++ b/acceptance/tests/pxp_agent_version.rb @@ -8,7 +8,9 @@ # Vendored Ruby needs to be on path for Windows/cygwin. # Only do this for cygwin because other OSes (Cisco Nexus) do not handle setting env values inline. if windows?(agent) then - version_command = "PATH=\"#{agent['privatebindir']}:$PATH\"" + " " + version_command + puppet_bindir = '/cygdrive/c/Program Files (x86)/Puppet Labs/Puppet/puppet/bin:'+ + '/cygdrive/c/Program Files/Puppet Labs/Puppet/puppet/bin' + version_command = "PATH=\"#{agent['privatebindir']}:#{puppet_bindir}:$PATH\"" + " " + version_command end on(agent, version_command) do |result| assert(/[0-9\.]*/ =~ result.stdout, "Version number should be numbers and periods but was \"#{result.stdout.to_s}\"")