Sha256: 75b550c0442405f0072cfed71c34dd02bcdb09a4a76ca6e59d595b4134ae6c3a
Contents?: true
Size: 482 Bytes
Versions: 6
Compression:
Stored size: 482 Bytes
Contents
require "spec_helper" describe '#parse_opts' do it 'should assign to :string option' do options = Reckon::Options.parse( %w[-f - --unattended --account bank], StringIO.new('foo,bar,baz') ) expect(options[:string]).to eq('foo,bar,baz') end it 'should require --unattended flag' do expect { Reckon::Options.parse(%w[-f - --account bank]) }.to( raise_error(RuntimeError, "--unattended is required to use STDIN as CSV source.") ) end end
Version data entries
6 entries across 6 versions & 1 rubygems