You can clone with
HTTPS or Subversion.
I have downloaded the OpsCode community cookbook to manage Chef Client. In that cookbook are some minitest tests, in the following hierarchy:
[bhatfield@bhatfield-mac chef-client]$ tree files/
└── [Oct 3 12:09] default/
└── [Oct 3 12:09] tests/
└── [Oct 3 12:09] minitest/
├── [Oct 3 12:09] config_test.rb
├── [Oct 3 12:09] cron_test.rb
├── [Oct 3 12:09] delete_validation_test.rb
├── [Oct 3 12:09] helpers.rb
└── [Oct 3 12:09] service_test.rb
Within the given tests, there is a cross dependency on helpers.rb, like so:
[bhatfield@bhatfield-mac chef-client]$ cat files/default/tests/minitest/service_test.rb
require File.expand_path('../helpers', __FILE__)
describe 'chef-client::service' do
it "starts the chef-client service" do
However, when running chef-client with minitest handler enabled, I get the following error:
ERROR: Report handler MiniTest::Chef::Handler raised #<LoadError: cannot load such file -- /var/chef/minitest/chef-client/helpers>
This was confusing to me, so I troubleshooted the 'require' code above, and determined that the file was not actually there, which is confirmed on the host:
vagrant@vagrant-ubuntu-oneric:/var/chef/minitest$ tree chef-client/
I am having a hard time understanding how I am getting into this state. What can I do to provide more troubleshooting data? Is there something I am not understanding about minitest-handler?
Brian, minitest-handler-cookbook copies the files to the host (defaulting to /var/chef/minitest). It looks like it expects support files to be in ../support, not ../helpers. See https://github.com/btm/minitest-handler-cookbook/blob/master/recipes/default.rb
I would recommend using support/
Did get your issue resolved @jimhopp ?
I believe there isn't an actionable task here. There has been no activity in a year, and I think the documentation covers where the acceptable places for support files are. If there is an actionable task here report back and we'll reopen this.