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

missing chef resource expectations in specs in 1.0.1 #367

Closed
thomasdziedzic opened this issue Sep 16, 2015 · 0 comments · Fixed by #368
Closed

missing chef resource expectations in specs in 1.0.1 #367

thomasdziedzic opened this issue Sep 16, 2015 · 0 comments · Fixed by #368

Comments

@thomasdziedzic
Copy link

In v1.0.0 the following worked in my spec:

expect(runner).to manage_elasticsearch_configure('elasticsearch')

In v1.0.1, the same line produces the following error:

Failure/Error: expect(runner).to manage_elasticsearch_configure('elasticsearch')
     NoMethodError:
       undefined method `manage_elasticsearch_configure'

I'm not sure which change in the diff caused it:
v1.0.0...v1.0.1

It appears that manage_elasticsearch_configure, configure_elasticsearch_service, and install_elasticsearch_plugin are broken.

It also appears that create_elasticsearch_user, install_elasticsearch still work.

I also couldn't find a test for manage_elasticsearch_configure or any of the other broken expectations in the codebase so maybe adding tests for those also would prevent this kind of failure? :)

edit: it appears that all that is needed is additional matchers in:
https://github.com/elastic/cookbook-elasticsearch/blob/master/libraries/matchers.rb

@martinb3 martinb3 modified the milestone: 1.1.x release Sep 17, 2015
@martinb3 martinb3 added this to the 1.0.2 bugfix release milestone Sep 20, 2015
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 a pull request may close this issue.

2 participants