31 lines
747 B
Ruby
31 lines
747 B
Ruby
# InSpec test for recipe kosmos_rsk::rskj
|
|
|
|
# The Chef InSpec reference, with examples and extensive documentation, can be
|
|
# found at https://docs.chef.io/inspec/resources/
|
|
|
|
describe user('rsk') do
|
|
it { should exist }
|
|
end
|
|
|
|
describe package('rskj') do
|
|
it { should be_installed }
|
|
its('version') { should eq '5.3.0~jammy' }
|
|
end
|
|
|
|
describe service('rsk') do
|
|
it { should be_enabled }
|
|
it { should be_installed }
|
|
it { should be_running }
|
|
end
|
|
|
|
describe port(4444) do
|
|
it { should be_listening }
|
|
end
|
|
|
|
describe parse_config_file('/etc/rsk/node.conf', {
|
|
assignment_regex: /^\s*([^=]*?)\s*=\s*(.*?)\s*$/
|
|
}) do
|
|
its(['blockchain.config.name']) { should eq '"testnet"' }
|
|
its(['database.dir']) { should eq '/var/lib/rsk/database/testnet' }
|
|
end
|