csv: allow all Ruby csv parsing options
Closes #149 Generalization on PR #146 by Qgel. Thanks for the contribution!
This commit is contained in:
@@ -67,6 +67,15 @@ describe Squib::Deck do
|
||||
})
|
||||
end
|
||||
|
||||
it 'loads custom CSV options' do
|
||||
hash = Squib.csv(file: csv_file('custom_opts.csv'),
|
||||
col_sep: '-', quote_char: '|')
|
||||
expect(hash).to eq({
|
||||
'x' => ['p'],
|
||||
'y' => ['q-r']
|
||||
})
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
context '#xlsx' do
|
||||
|
||||
Reference in New Issue
Block a user