Sha256: a86489aba54f5c9e44afa23d02458d24aa3d74b1d746a6c7c29132283406c279
Contents?: true
Size: 1.1 KB
Versions: 1
Compression:
Stored size: 1.1 KB
Contents
describe FlareUp::STLLoadErrorFetcher do describe '.fetch_errors' do let(:connection) { instance_double('FlareUp::Connection') } before do expect(connection).to receive(:execute). with('SELECT * FROM stl_load_errors ORDER BY query DESC, line_number, position LIMIT 1'). and_return([ { 'err_reason' => 'TEST_REASON', 'raw_field_value' => 'TEST_RAW_FIELD_VALUE', 'raw_line' => 'TEST_RAW_LINE', 'col_length' => '1', 'type' => 'TEST_TYPE', 'colname' => 'TEST_COLNAME', 'filename' => 'TEST_FILENAME', 'position' => '2', 'line_number' => '3' } ]) end it 'should return the load errors' do expect(FlareUp::STLLoadErrorFetcher.fetch_errors(connection)).to eq( [ FlareUp::STLLoadError.new( 'TEST_REASON', 'TEST_RAW_FIELD_VALUE', 'TEST_RAW_LINE', 1, 'TEST_TYPE', 'TEST_COLNAME', 'TEST_FILENAME', 2, 3 ) ] ) end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
flare-up-0.2 | spec/lib/flare_up/stl_load_error_fetcher_spec.rb |