Bolt 3.15.0 is now available

Skip to first unread message

Puppet Product Update

Aug 2, 2021, 8:21:22 PMAug 2

VERSION 3.15.0

in this release

✨  new features

  • You can now use --clear-cache to clear the plan/task metadata caches
  • The apply_prep function now accepts the _catch_errors parameter.
  • The bolt apply and Invoke-BoltApply commands set  _catch_errors to true, allowing an apply action to complete on as many targets as possible instead of erroring if even one target fails the apply_prep portion of the command.
  • Bolt now respects the @api tag in Puppet language plans. If the @api private tag is present, the plan will be hidden from bolt plan show and Get-BoltPlan output.

🔧  bug fixes

  • bolt.gemspec now includes the new guide files.

🚨  deprecations

  • The @private tag for Puppet language plans is deprecated. Use the @api tag instead.

in the works

  • Further changes and improvements to the way scripts are loaded.

nuts and bolts

Each month, we'll highlight a different Bolt feature and cover the details on what it is, why you might want to use it, and how it can be used in your workflows.

August's highlighted feature is: BoltSpec!

What is BoltSpec?

BoltSpec is a library of helpers that ships with Bolt. It is intended to be used with RSpec, a testing tool, to write unit tests for your plans. Specifically, BoltSpec's helpers let you test the behavior of your plans without the need to connect to targets.

Why should I use BoltSpec?

Because plans can include complex logic that automates different jobs, it's important to test that the plan behaves as you expect. BoltSpec lets you easily write tests for your plans so you can test their behavior in development and catch any errors before your plans are used in production. Also, because BoltSpec stubs out Bolt functions that connect to targets, you don't need to worry about provisioning containers or VMs to run these tests.

How do I use BoltSpec?

Using BoltSpec is as easy as installing and configuring rspec-puppet for your module or project, and then adding a couple lines to your tests' configuration file. If you already develop Puppet modules using the Puppet Development Kit (PDK), then most of this is already done for you.

Going over all the details of using BoltSpec to test your plans is a little much for an email. So if you're interested in testing your plans, why not check out our new Testing Plans documentation?

Tw Yt In

Bolt Documentation

Reply all
Reply to author
0 new messages