Test suite scaffolding generator
Stop writing tests by hand.
Puppet Retrospec is the only tool you need to generate puppet code, tests, modules, facts, types, providers, data and everything else.
Stop writing tests by hand.
Over 1,000,000+ hours saved.
Prettify your modules.
Stop writing modules by hand.
Change whatever you need.
Keep your modules up-to-date.
gem install puppet-retrospec
cd [your-module-directory]
retrospec puppet
# Options:
-n, --name= The name of the task you wish to create
-p, --task-params= The task parameter names separated by commas (default: name)
-t, --task-type= The task type of the task (bash, generic, ruby, python, node, powershell) (default: bash)
# Examples:
retrospec puppet new_task -n my_task
retrospec puppet new_task -n my_task -p my_param_1,my_param_2
retrospec puppet new_task -n my_taks -t ruby
# Options:
# -n, --name= The name of the fact you wish to create
# Examples:
retrospec puppet new_fact -n my_fact
# Options:
# -n, --name= The name of the provider you wish to create
# -t, --type= The type name of the provider
# Examples:
retrospec puppet new_provider -n my_provider -t my_provider_type
# Options:
# -n, --name= The name of the function you wish to create
# -t, --type= The version type of the function (v3,v4,native) (default: v4)
# -u, --test-type= The type of test file to create (rspec, ruby) (default: rspec)
# -r, --return-type= The return type of the function (rvalue, statement) (default: rvalue)
# Examples:
retrospec puppet new_function -n my_function
retrospec puppet new_function -n my_function -t v3
retrospec puppet new_function -n my_function -u ruby
retrospec puppet new_function -n my_function -r statement
# Options:
# -b, --backend-type= Which hiera backend type to use (hiera, data_hash, lookup_key, data_dig) (default: hiera)
# -n, --backend-name= The name of the custom backend (default: custom)
# -t, --function-type= What type of function to create the backend type with (native or v4) (default: native)
# Examples:
retrospec puppet module_data
retrospec puppet module_data -b data_hash
retrospec puppet module_data -n my_backend
retrospec puppet module_data -t v4
I hope you find Retrospec Puppet useful.
Feel free to get in touch if you have any questions or suggestions.