Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix failing provider RSpec test when running on docker #156

Merged
merged 1 commit into from
Jul 30, 2015

Conversation

juniorsysadmin
Copy link
Member

This hack mocks an exit success so that the test does not fail when
run on docker.

This hack mocks an exit success so that the test does not fail when
run on docker.
@juniorsysadmin
Copy link
Member Author

For whatever reason $CHILD_STATUS.success does not evaluate to true when this test is run on TravisCI.

Puppet.debug("Warning: npm list --json exited with code #{$CHILD_STATUS.exitstatus}") unless $CHILD_STATUS.success?

This is a hack because there's no way to reproduce a way that npm will produce non-JSON output with npm list -g --json without a resulting exit failure - this is a unit test just for coverage that doesn't reflect normal output. Ideally, we probably would want to test the existence of both Puppet.debug statements being the output, but I couldn't think of a way to do this.

igalic added a commit that referenced this pull request Jul 30, 2015
Fix failing provider RSpec test when running on docker
@igalic igalic merged commit b9d2528 into voxpupuli:master Jul 30, 2015
@igalic
Copy link
Contributor

igalic commented Jul 30, 2015

thanks @juniorsysadmin!

@juniorsysadmin juniorsysadmin deleted the sudo-off branch August 1, 2015 08:18
cegeka-jenkins pushed a commit to cegeka/puppet-nodejs that referenced this pull request Oct 23, 2017
Fix failing provider RSpec test when running on docker
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants