Skip to content

Add a generic rspec module, and use and test it via the generator script. #408

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

Merged
merged 1 commit into from
Aug 10, 2015

Conversation

randomcamel
Copy link
Contributor

No description provided.

end
include_context "run with driver", :driver_string => "#{snake_name}"

with_chef_server do
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this need to be the when_the_chef_12_server like we have in all the AWS tests? I like with_chef_server much better but I am curious about what the switch means

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nope, with_chef_server actually calls when_the_chef_12_server, but

  1. with a clearer name, and
  2. with default values.

All the chef-provisioning-aws invocations look like

when_the_chef_12_server "exists", organization: 'foo', server_scope: :context

and this encapsulates (overridable) defaults

organization: "spec_tests", server_scope: :context, port: 8900..9000

@tyler-ball
Copy link
Contributor

This is awesome. I have 1 question but I am 👍 on this and you can merge it

… can include to

easily load the driver for testing.

- Wrap 'when_the_chef_12_server' in 'with_chef_server' with common defaults (which can be
  overridden).
- Rake tasks to automate testing the driver generator and specs.
- Add required version restrictions in the generated Gemfile.
- Add some basic reality-checking specs to the generated driver, including a loading a new
  no-op resource in the new driver.
- Add 'rake cycle' to Travis to run the whole generate-test sequence.
randomcamel added a commit that referenced this pull request Aug 10, 2015
Add a generic rspec module, and use and test it via the generator script.
@randomcamel randomcamel merged commit 715cf2c into master Aug 10, 2015
@randomcamel randomcamel deleted the cd/generic-specs branch August 10, 2015 22:29
randomcamel added a commit that referenced this pull request Aug 19, 2015
Add a generic rspec module, and use and test it via the generator script.
@tas50 tas50 added Type: Enhancement Adds new functionality. and removed New Feature labels Jul 31, 2018
bglimepoint pushed a commit to bglimepoint/chef-provisioning that referenced this pull request Oct 29, 2018
Add a generic rspec module, and use and test it via the generator script.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Enhancement Adds new functionality.
Development

Successfully merging this pull request may close these issues.

4 participants