test/test_config.rb in mpw-4.1.1 vs test/test_config.rb in mpw-4.2.0
- old
+ new
@@ -18,33 +18,35 @@
I18n.default_locale = :en
I18n.locale = lang.to_sym
end
def test_00_config
- data = { gpg_key: 'test@example.com',
- lang: 'en',
- wallet_dir: '/tmp/test',
- gpg_exe: '',
- }
+ data = {
+ gpg_key: 'test@example.com',
+ lang: 'en',
+ wallet_dir: '/tmp/test',
+ gpg_exe: ''
+ }
@config = MPW::Config.new
@config.setup(data)
@config.load_config
- data.each do |k,v|
+ data.each do |k, v|
assert_equal(v, @config.send(k))
end
@config.setup_gpg_key('password', 'test@example.com', 2048)
assert(@config.check_gpg_key?)
end
def test_01_password
- data = { pwd_alpha: false,
- pwd_numeric: false,
- pwd_special: true,
- pwd_length: 32,
- }
+ data = {
+ pwd_alpha: false,
+ pwd_numeric: false,
+ pwd_special: true,
+ pwd_length: 32
+ }
@config = MPW::Config.new
@config.load_config
assert_equal(@config.password[:length], 16)