Sha256: bc6cf0b6a5a482c466ff497d872510eb97900cb96776d5b0b68d97167dc3b031
Contents?: true
Size: 736 Bytes
Versions: 3
Compression:
Stored size: 736 Bytes
Contents
# frozen_string_literal: true describe 'Plugins(toml): #load_from_self => format: :toml', plugin: :toml do specify ':toml-format support' do class TomlEndDataConfig < Qonfig::DataSet load_from_self format: :toml end config = TomlEndDataConfig.new expect(config.settings.amount).to eq(123.456) expect(config.settings.methods).to eq([['test'], [true, false], [1, 2, 3]]) expect(config.settings.credentials.user).to eq('admin') expect(config.settings.credentials.password).to eq('123') expect(config.settings.credentials.enabled).to eq(true) end end __END__ amount = 123.456 methods = [ [ "test" ], [ true, false ], [ 1, 2, 3 ] ] [credentials] user = "admin" password = "123" enabled = true
Version data entries
3 entries across 3 versions & 1 rubygems