This repository was archived by the owner on Feb 13, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 38
Expand file tree
/
Copy pathsdk_spec.rb
More file actions
82 lines (71 loc) · 2.31 KB
/
sdk_spec.rb
File metadata and controls
82 lines (71 loc) · 2.31 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
require 'spec_helper'
describe "android::sdk" do
let(:pre_condition) { 'include android' }
context '64bit RedHat', :compile do
it { should contain_package('glibc.i686') }
it { should contain_package('zlib.i686') }
it { should contain_package('libstdc++.i686') }
it { should contain_file('android-executable').with({
'path' => '/usr/local/android/android-sdk-linux/tools/android',
'mode' => '0755',
}).that_requires('Exec[unpack-androidsdk]')
}
end
context '64bit RedHat, custom installdir', :compile do
let(:pre_condition) { 'class { "android": installdir => "/opt/android" }' }
it { should contain_file('android-executable').with({
'path' => '/opt/android/android-sdk-linux/tools/android',
'mode' => '0755',
}).that_requires('Exec[unpack-androidsdk]')
}
end
context '64bit Debian, x86_64 architecture', :compile do
let(:facts) { {
:operatingsystem => 'Ubuntu',
:osfamily => 'Debian'
} }
it { should contain_package('ia32-libs') }
end
context '64bit Debian, amd64 architecture', :compile do
let(:facts) { {
:operatingsystem => 'Ubuntu',
:osfamily => 'Debian',
:architecture => 'amd64'
} }
it { should contain_package('ia32-libs') }
end
context '64bit Debian Jessie, x86_64 architecture', :compile do
let(:facts) { {
:operatingsystem => 'Debian',
:osfamily => 'Debian'
:lsbdistcodename => 'jessie'
} }
it { should_not contain_package('ia32-libs') }
end
context '64bit Debian Jessie, amd64 architecture', :compile do
let(:facts) { {
:operatingsystem => 'Debian',
:osfamily => 'Debian',
:lsbdistcodename => 'jessie'
:architecture => 'amd64'
} }
it { should_not contain_package('ia32-libs') }
end
context '64bit Ubuntu 14.04, x86_64 architecture', :compile do
let(:facts) { {
:operatingsystem => 'Ubuntu',
:osfamily => 'Debian'
:lsbdistrelease => '14.04'
} }
it { should_not contain_package('ia32-libs') }
end
context '64bit Ubuntu 14.04, amd64 architecture', :compile do
let(:facts) { {
:operatingsystem => 'Ubuntu',
:osfamily => 'Debian',
:lsbdistrelease => '14.04'
:architecture => 'amd64'
} }
it { should_not contain_package('ia32-libs') }
end
end