Force owner and mode on ppa files
[puppet-modules/puppetlabs-apt.git] / spec / acceptance / apt_builddep_spec.rb
1 require 'spec_helper_acceptance'
2
3 describe 'apt::builddep' do
4
5   context 'reset' do
6     it 'removes packages' do
7       shell('apt-get -y remove glusterfs-server')
8       shell('apt-get -y remove g++')
9     end
10   end
11
12   context 'apt::builddep' do
13     it 'should work with no errors' do
14       pp = <<-EOS
15       include '::apt'
16       apt::builddep { 'glusterfs-server': }
17       EOS
18
19       apply_manifest(pp, :catch_failures => true)
20     end
21
22     describe 'should install g++ as a dependency' do
23       describe package('g++') do
24         it { should be_installed }
25       end
26     end
27   end
28
29   context 'reset' do
30     it 'removes packages' do
31       shell('apt-get -y remove glusterfs-server')
32       shell('apt-get -y remove g++')
33     end
34   end
35
36 end