From aa24b2d25da89f4598dcdfc0e45bcdcb204c9ab3 Mon Sep 17 00:00:00 2001 From: Aaron Stone Date: Sun, 14 Jul 2013 20:00:55 -0700 Subject: Fix git tests broken by dcd0d14 --- spec/unit/puppet/provider/vcsrepo/git_spec.rb | 2 ++ 1 file changed, 2 insertions(+) (limited to 'spec/unit/puppet/provider/vcsrepo') diff --git a/spec/unit/puppet/provider/vcsrepo/git_spec.rb b/spec/unit/puppet/provider/vcsrepo/git_spec.rb index 4e4d9f3..cb6c0c6 100644 --- a/spec/unit/puppet/provider/vcsrepo/git_spec.rb +++ b/spec/unit/puppet/provider/vcsrepo/git_spec.rb @@ -8,6 +8,7 @@ describe_provider :vcsrepo, :git, :resource => {:path => '/tmp/vcsrepo'} do context "with a revision that is a remote branch", :resource => {:revision => 'only/remote'} do it "should execute 'git clone' and 'git checkout -b'" do provider.expects(:git).with('clone', resource.value(:source), resource.value(:path)) + expects_chdir('/') expects_chdir provider.expects(:update_submodules) provider.expects(:git).with('branch', '-a').returns(resource.value(:revision)) @@ -18,6 +19,7 @@ describe_provider :vcsrepo, :git, :resource => {:path => '/tmp/vcsrepo'} do context "with a revision that is not a remote branch", :resource => {:revision => 'a-commit-or-tag'} do it "should execute 'git clone' and 'git reset --hard'" do provider.expects(:git).with('clone', resource.value(:source), resource.value(:path)) + expects_chdir('/') expects_chdir provider.expects(:update_submodules) provider.expects(:git).with('branch', '-a').returns(resource.value(:revision)) -- cgit v1.2.3