示例#1
0
 def test_midlist_missing( self ):
     sffn, sffp = self.sffs.items()[0]
     reg = int( sffn.replace( '.sff', '' )[-2:] )
     process = demultiplex.demultiplex_sff( sffp, fixtures.MIDPARSE, self.rf[reg].keys() + ['RL99'], self.sfffilecmd, self.tempdir )
     stdout, stderr = process.communicate()
     read_lst = self.expected_read_list[sffn.replace( '.sff', '.lst' )]
     with open( read_lst ) as fh:
         result = fh.read() + '  '+fixtures.MIDPREFIX+'RL99:  0 reads found\n'
         common.erdiff( result, stdout )
示例#2
0
 def test_demultiplex_sff( self ):
     ''' Should match expected output from fixtures '''
     for sffn, sffp in self.sffs.items():
         reg = int( sffn.replace( '.sff', '' )[-2:] )
         read_lst = self.expected_read_list[sffn.replace( '.sff', '.lst' )]
         process = demultiplex.demultiplex_sff( sffp, fixtures.MIDPARSE, self.rf[reg].keys(), self.sfffilecmd, self.tempdir )
         stdout, stderr = process.communicate()
         with open( read_lst ) as fh:
             common.erdiff( fh.read(), stdout )
示例#3
0
 def test_midlist_missingrev( self ):
     ''' Make sure only midkey list barcodes are extracted '''
     sffn, sffp = self.sffs.items()[0]
     reg = int( sffn.replace( '.sff', '' )[-2:] )
     keys = demultiplex.sort_midlist( self.rf[reg].keys() )[:-2]
     process = demultiplex.demultiplex_sff( sffp, fixtures.MIDPARSE, keys, self.sfffilecmd, self.tempdir )
     stdout, stderr = process.communicate()
     read_lst = self.expected_read_list[sffn.replace( '.sff', '.lst' )]
     with open( read_lst ) as fh:
         expect = "".join(fh.readlines()[:-2])
         common.erdiff( expect, stdout )
示例#4
0
 def test_midlist_missing(self):
     sffn, sffp = self.sffs.items()[0]
     reg = int(sffn.replace('.sff', '')[-2:])
     process = demultiplex.demultiplex_sff(sffp, fixtures.MIDPARSE,
                                           self.rf[reg].keys() + ['RL99'],
                                           self.sfffilecmd, self.tempdir)
     stdout, stderr = process.communicate()
     read_lst = self.expected_read_list[sffn.replace('.sff', '.lst')]
     with open(read_lst) as fh:
         result = fh.read(
         ) + '  ' + fixtures.MIDPREFIX + 'RL99:  0 reads found\n'
         common.erdiff(result, stdout)
示例#5
0
 def test_demultiplex_sff(self):
     ''' Should match expected output from fixtures '''
     for sffn, sffp in self.sffs.items():
         reg = int(sffn.replace('.sff', '')[-2:])
         read_lst = self.expected_read_list[sffn.replace('.sff', '.lst')]
         process = demultiplex.demultiplex_sff(sffp, fixtures.MIDPARSE,
                                               self.rf[reg].keys(),
                                               self.sfffilecmd,
                                               self.tempdir)
         stdout, stderr = process.communicate()
         with open(read_lst) as fh:
             common.erdiff(fh.read(), stdout)
示例#6
0
 def test_midlist_missingrev(self):
     ''' Make sure only midkey list barcodes are extracted '''
     sffn, sffp = self.sffs.items()[0]
     reg = int(sffn.replace('.sff', '')[-2:])
     keys = demultiplex.sort_midlist(self.rf[reg].keys())[:-2]
     process = demultiplex.demultiplex_sff(sffp, fixtures.MIDPARSE, keys,
                                           self.sfffilecmd, self.tempdir)
     stdout, stderr = process.communicate()
     read_lst = self.expected_read_list[sffn.replace('.sff', '.lst')]
     with open(read_lst) as fh:
         expect = "".join(fh.readlines()[:-2])
         common.erdiff(expect, stdout)