Note that exim contains tracker-specific configuration
[mirror/dsa-puppet.git] / 3rdparty / modules / stdlib / spec / functions / any2array_spec.rb
1 require 'spec_helper'
2
3 describe 'any2array' do
4   it { is_expected.not_to eq(nil) }
5   it { is_expected.to run.with_params.and_return([]) }
6   it { is_expected.to run.with_params('').and_return([]) }
7   it { is_expected.to run.with_params(true).and_return([true]) }
8   it { is_expected.to run.with_params('one').and_return(['one']) }
9   it { is_expected.to run.with_params('one', 'two').and_return(['one', 'two']) }
10   it { is_expected.to run.with_params([]).and_return([]) }
11   it { is_expected.to run.with_params(['one']).and_return(['one']) }
12   it { is_expected.to run.with_params(['one', 'two']).and_return(['one', 'two']) }
13   it { is_expected.to run.with_params({}).and_return([]) }
14   it { is_expected.to run.with_params('key' => 'value').and_return(['key', 'value']) }
15
16   it { is_expected.to run.with_params('‰').and_return(['‰']) }
17   it { is_expected.to run.with_params('竹').and_return(['竹']) }
18   it { is_expected.to run.with_params('Ü').and_return(['Ü']) }
19   it { is_expected.to run.with_params('∇').and_return(['∇']) }
20   it { is_expected.to run.with_params('€', '万', 'Ö', '♥', '割').and_return(['€', '万', 'Ö', '♥', '割']) }
21 end