Sha256: 66228e62211f0d125a4db392b4e2a4bb511cb42bf99acd6a00e940e709eb096f
Contents?: true
Size: 785 Bytes
Versions: 6
Compression:
Stored size: 785 Bytes
Contents
require 'spec_helper' class FakeProcessor; end; RSpec.describe CanvasSync::Jobs::ReportProcessorJob do let(:report_name) { 'provisioning_csv' } let(:report_url) { 'https://test.instructure.com/sample_report_download' } let(:processor) { FakeProcessor.to_s } let(:job_chain) { ['another-job'] } describe '#perform' do it 'downloads the report to a file and then calls the process method on the processor, and then invokes the next job' do expect(IO).to receive(:copy_stream) expect(FakeProcessor).to receive(:process) expect(CanvasSync).to receive(:invoke_next).with(job_chain) CanvasSync::Jobs::ReportProcessorJob.perform_now( job_chain, report_name, report_url, processor, {} ) end end end
Version data entries
6 entries across 6 versions & 1 rubygems