[chef] Re: Checking that a dcirectory exists with ChefSpec/RSpec


Chronological Thread 
  • From: Noah Kantrowitz < >
  • To:
  • Subject: [chef] Re: Checking that a dcirectory exists with ChefSpec/RSpec
  • Date: Mon, 22 Jun 2015 11:29:55 -0700


On Jun 22, 2015, at 11:28 AM, Sean Farrow 
< >
 wrote:

> Hi,
>  
> I’ve got a unit test that uses another recipe to install chocolatey. I want 
> to check that the folder that chocolatey is installed to exists. Given that 
> the recipe doesn’t create the folder, what is the best way of doing this 
> using ChefSpec?
> Kind regards
> Sean.

Assuming you use a directory resource to create it, expect(chef_run).to 
create_directory('c:\\whatever')

--Noah

Attachment: signature.asc
Description: Message signed with OpenPGP using GPGMail




Archive powered by MHonArc 2.6.16.

§