Sha256: 73c7d4a0de399ae0885d3bed4abd0bc994e21a5cecbbdfae8d7ab01011528aaa

Contents?: true

Size: 1.21 KB

Versions: 3

Compression:

Stored size: 1.21 KB

Contents

require 'spec_helper'

describe Lederhosen::Trimmer do

  describe Lederhosen::Trimmer::PairedTrimmer do

  end

  describe Lederhosen::Trimmer::QSEQTrimmer do

    let(:qseq_trimmer) { Lederhosen::Trimmer::QSEQTrimmer.new 'spec/data/ILT_L_9_B_001_1.txt.gz', 'spec/data/ILT_L_9_B_001_3.txt.gz' }

    it 'can be initialized' do
      qseq_trimmer.should_not be_nil
    end

    it 'has an #each function that generates record objects' do 
      qseq_trimmer.each do |x|
        x.should be_an_instance_of Fasta
      end
    end

    it 'should create an even number of records (not output singletons)' do
      qseq_trimmer.to_a.flatten.size.should be_even
    end
  end

  describe Lederhosen::Trimmer::InterleavedTrimmer do

    let(:interleaved_trimmer) { Lederhosen::Trimmer::InterleavedTrimmer.new 'spec/data/example.fastq' }

    it 'can be initialized' do
      interleaved_trimmer.should_not be_nil
    end

    it 'has an #each function that generates record objects' do 
      interleaved_trimmer.each do |x|
        x.should be_an_instance_of Fasta
      end
    end

    it 'should create an even number of records (not output singletons)' do
      interleaved_trimmer.to_a.flatten.size.should be_even
    end
  end

end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
lederhosen-1.6.2 spec/trimmer_spec.rb
lederhosen-1.6.1 spec/trimmer_spec.rb
lederhosen-1.6.0 spec/trimmer_spec.rb