FastQFileTest.cpp
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018 #include "FastQFile.h"
00019 #include <assert.h>
00020
00021 const String FIRST_SEQID_LINE = "@Valid with comment";
00022 const String FIRST_SEQID = "Valid";
00023 const String FIRST_RAW_SEQ = "ACTGNactng.0123";
00024 const String FIRST_PLUS_LINE = "+";
00025 const String FIRST_QUALITY = "!#\"$%&'()*+,-./";
00026 const String SECOND_SEQID_LINE = "@Valid1 with comment";
00027 const String SECOND_SEQID = "Valid1";
00028 const String SECOND_RAW_SEQ = "ACTGACTNactngaac";
00029 const String SECOND_PLUS_LINE = "+";
00030 const String SECOND_QUALITY = "0123456789:;<=>@";
00031 const String THIRD_SEQID_LINE = "@Valid2";
00032 const String THIRD_SEQID = "Valid2";
00033 const String THIRD_RAW_SEQ = "A123.0321.011";
00034 const String THIRD_PLUS_LINE = "+";
00035 const String THIRD_QUALITY = "?@ABCDEFGHIJK";
00036 const String FOURTH_SEQID_LINE = "@Valid3";
00037 const String FOURTH_SEQID = "Valid3";
00038 const String FOURTH_RAW_SEQ = "ACTGACTNactngACTGACTNactng";
00039 const String FOURTH_PLUS_LINE = "+";
00040 const String FOURTH_QUALITY = "LMNOPQRSTUVWXYZ[\\]^_'abcde";
00041 const String FIFTH_SEQID_LINE = "@Valid4";
00042 const String FIFTH_SEQID = "Valid4";
00043 const String FIFTH_RAW_SEQ = "ACTGACTNactngACTGACTNactng";
00044 const String FIFTH_PLUS_LINE = "+";
00045 const String FIFTH_QUALITY = "fghijklmnopqrstuvwxyz{|}~~";
00046 const String SIXTH_SEQID_LINE = "@";
00047 const String SIXTH_SEQID = "";
00048 const String SIXTH_RAW_SEQ = "ACTGACTNactng";
00049 const String SIXTH_PLUS_LINE = "+";
00050 const String SIXTH_QUALITY = "?@ABCDEFGHIJK";
00051 const String SEVENTH_SEQID_LINE = "Line no start with @";
00052 const String SEVENTH_SEQID = "";
00053 const String SEVENTH_RAW_SEQ = "ACTGACTNactng";
00054 const String SEVENTH_PLUS_LINE = "+";
00055 const String SEVENTH_QUALITY = "LMNOPQRSTUVWX";
00056 const String EIGHTH_SEQID_LINE = "@ a";
00057 const String EIGHTH_SEQID = "";
00058 const String EIGHTH_RAW_SEQ = "ACTGACTNactng";
00059 const String EIGHTH_PLUS_LINE = "+";
00060 const String EIGHTH_QUALITY = "YZ[\\]^_'abcde";
00061 const String NINTH_SEQID_LINE = "@ ";
00062 const String NINTH_SEQID = "";
00063 const String NINTH_RAW_SEQ = "ACTGACTNactng";
00064 const String NINTH_PLUS_LINE = "+";
00065 const String NINTH_QUALITY = "fghijklmnopqr";
00066 const String TENTH_SEQID_LINE = "@Valid";
00067 const String TENTH_SEQID = "Valid";
00068 const String TENTH_RAW_SEQ = "ACTGNactng";
00069 const String TENTH_PLUS_LINE = "+";
00070 const String TENTH_QUALITY = "!#\"$%&'()*";
00071 const String ELEVENTH_SEQID_LINE = "@RawError1";
00072 const String ELEVENTH_SEQID = "RawError1";
00073 const String ELEVENTH_RAW_SEQ = "ACTNaHtng0aBZa";
00074 const String ELEVENTH_PLUS_LINE = "+";
00075 const String ELEVENTH_QUALITY = "ACTNactng0aBaZ";
00076 const String TWELFTH_SEQID_LINE = "@RawError2";
00077 const String TWELFTH_SEQID = "RawError2";
00078 const String TWELFTH_RAW_SEQ = "aaa";
00079 const String TWELFTH_PLUS_LINE = "+";
00080 const String TWELFTH_QUALITY = "aaa";
00081 const String THIRTEENTH_SEQID_LINE = "@RawError3";
00082 const String THIRTEENTH_SEQID = "RawError3";
00083 const String THIRTEENTH_RAW_SEQ = "ACTGACTNactng";
00084 const String THIRTEENTH_PLUS_LINE = "+";
00085 const String THIRTEENTH_QUALITY = "ACTGACTNactng";
00086 const String FOURTEENTH_SEQID_LINE = "@QualityError1";
00087 const String FOURTEENTH_SEQID = "QualityError1";
00088 const String FOURTEENTH_RAW_SEQ = "ACTGCacgnc";
00089 const String FOURTEENTH_PLUS_LINE = "+";
00090 const String FOURTEENTH_QUALITY = "ac gcacg n";
00091 const String FIFTEENTH_SEQID_LINE = "@QualityError2";
00092 const String FIFTEENTH_SEQID = "QualityError2";
00093 const String FIFTEENTH_RAW_SEQ = "ACTGCacgnc";
00094 const String FIFTEENTH_PLUS_LINE = "+";
00095 const String FIFTEENTH_QUALITY = "actgc@cgnc";
00096 const String SIXTEENTH_SEQID_LINE = "@QualityError3";
00097 const String SIXTEENTH_SEQID = "QualityError3";
00098 const String SIXTEENTH_RAW_SEQ = "ACTGCacgnc";
00099 const String SIXTEENTH_PLUS_LINE = "+";
00100 const String SIXTEENTH_QUALITY = "actgc77acgnc";
00101 const String SEVENTEENTH_SEQID_LINE = "@PlusValid1";
00102 const String SEVENTEENTH_SEQID = "PlusValid1";
00103 const String SEVENTEENTH_RAW_SEQ = "ACTGCacgnc";
00104 const String SEVENTEENTH_PLUS_LINE = "+PlusValid1";
00105 const String SEVENTEENTH_QUALITY = "actgcacgnc";
00106 const String EIGHTEENTH_SEQID_LINE = "@PlusValid2";
00107 const String EIGHTEENTH_SEQID = "PlusValid2";
00108 const String EIGHTEENTH_RAW_SEQ = "ACTGCacgnc";
00109 const String EIGHTEENTH_PLUS_LINE = "+PlusValid2 Added comment";
00110 const String EIGHTEENTH_QUALITY = "actgcacgnc";
00111 const String NINETEENTH_SEQID_LINE = "@PlusError1";
00112 const String NINETEENTH_SEQID = "PlusError1";
00113 const String NINETEENTH_RAW_SEQ = "ACTGCacgnc";
00114 const String NINETEENTH_PLUS_LINE = "+PlusError2";
00115 const String NINETEENTH_QUALITY = "actgcacgnc";
00116
00117 const String TWENTIETH_SEQID_LINE = "@InvalidColor";
00118 const String TWENTIETH_SEQID = "InvalidColor";
00119 const String TWENTIETH_RAW_SEQ = "0123.0321.011";
00120 const String TWENTIETH_PLUS_LINE = "+";
00121 const String TWENTIETH_QUALITY = "0123.0321.011";
00122
00123
00124 const String TWENTY_FIRST_SEQID_LINE = "@PlusError2";
00125 const String TWENTY_FIRST_SEQID = "PlusError2";
00126 const String TWENTY_FIRST_RAW_SEQ = "ACTGCacgnc";
00127 const String TWENTY_FIRST_PLUS_LINE = "";
00128 const String TWENTY_FIRST_QUALITY = "";
00129
00130 void testReadUnOpenedFile()
00131 {
00132 FastQFile fastqfile;
00133
00134 assert(fastqfile.isOpen() == false);
00135 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_ORDER_ERROR);
00136 assert(fastqfile.isOpen() == false);
00137 }
00138
00139 void testOpenFile()
00140 {
00141 FastQFile fastqfile;
00142
00143
00144 assert(fastqfile.isOpen() == false);
00145 assert(fastqfile.openFile("noexist.txt", BaseAsciiMap::UNKNOWN) == FastQStatus::FASTQ_OPEN_ERROR);
00146 assert(fastqfile.isOpen() == false);
00147
00148
00149 }
00150
00151
00152 void testCloseFile()
00153 {
00154 FastQFile fastqfile;
00155
00156
00157 assert(fastqfile.isOpen() == false);
00158 assert(fastqfile.closeFile() == FastQStatus::FASTQ_SUCCESS);
00159 assert(fastqfile.isOpen() == false);
00160 }
00161
00162
00163 void testReadSequence()
00164 {
00165 FastQFile fastqfile;
00166
00167 assert(fastqfile.isOpen() == false);
00168 assert(fastqfile.openFile("testFile.txt") == FastQStatus::FASTQ_SUCCESS);
00169
00170 assert(fastqfile.isOpen() == true);
00171
00172 assert(fastqfile.getSpaceType() == BaseAsciiMap::UNKNOWN);
00173
00174
00175 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00176 assert(fastqfile.mySequenceIdLine == FIRST_SEQID_LINE);
00177 assert(fastqfile.mySequenceIdentifier == FIRST_SEQID);
00178 assert(fastqfile.myRawSequence == FIRST_RAW_SEQ);
00179 assert(fastqfile.myPlusLine == FIRST_PLUS_LINE);
00180 assert(fastqfile.myQualityString == FIRST_QUALITY);
00181 assert(fastqfile.getSpaceType() == BaseAsciiMap::BASE_SPACE);
00182
00183 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00184 assert(fastqfile.mySequenceIdLine == SECOND_SEQID_LINE);
00185 assert(fastqfile.mySequenceIdentifier == SECOND_SEQID);
00186 assert(fastqfile.myRawSequence == SECOND_RAW_SEQ);
00187 assert(fastqfile.myPlusLine == SECOND_PLUS_LINE);
00188 assert(fastqfile.myQualityString == SECOND_QUALITY);
00189
00190 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00191 assert(fastqfile.mySequenceIdLine == THIRD_SEQID_LINE);
00192 assert(fastqfile.mySequenceIdentifier == THIRD_SEQID);
00193 assert(fastqfile.myRawSequence == THIRD_RAW_SEQ);
00194 assert(fastqfile.myPlusLine == THIRD_PLUS_LINE);
00195 assert(fastqfile.myQualityString == THIRD_QUALITY);
00196
00197 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00198 assert(fastqfile.mySequenceIdLine == FOURTH_SEQID_LINE);
00199 assert(fastqfile.mySequenceIdentifier == FOURTH_SEQID);
00200 assert(fastqfile.myRawSequence == FOURTH_RAW_SEQ);
00201 assert(fastqfile.myPlusLine == FOURTH_PLUS_LINE);
00202 assert(fastqfile.myQualityString == FOURTH_QUALITY);
00203
00204 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00205 assert(fastqfile.mySequenceIdLine == FIFTH_SEQID_LINE);
00206 assert(fastqfile.mySequenceIdentifier == FIFTH_SEQID);
00207 assert(fastqfile.myRawSequence == FIFTH_RAW_SEQ);
00208 assert(fastqfile.myPlusLine == FIFTH_PLUS_LINE);
00209 assert(fastqfile.myQualityString == FIFTH_QUALITY);
00210
00211 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00212 assert(fastqfile.mySequenceIdLine == SIXTH_SEQID_LINE);
00213 assert(fastqfile.mySequenceIdentifier == SIXTH_SEQID);
00214 assert(fastqfile.myRawSequence == SIXTH_RAW_SEQ);
00215 assert(fastqfile.myPlusLine == SIXTH_PLUS_LINE);
00216 assert(fastqfile.myQualityString == SIXTH_QUALITY);
00217
00218 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00219 assert(fastqfile.mySequenceIdLine == SEVENTH_SEQID_LINE);
00220 assert(fastqfile.mySequenceIdentifier == SEVENTH_SEQID);
00221 assert(fastqfile.myRawSequence == SEVENTH_RAW_SEQ);
00222 assert(fastqfile.myPlusLine == SEVENTH_PLUS_LINE);
00223 assert(fastqfile.myQualityString == SEVENTH_QUALITY);
00224
00225 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00226 assert(fastqfile.mySequenceIdLine == EIGHTH_SEQID_LINE);
00227 assert(fastqfile.mySequenceIdentifier == EIGHTH_SEQID);
00228 assert(fastqfile.myRawSequence == EIGHTH_RAW_SEQ);
00229 assert(fastqfile.myPlusLine == EIGHTH_PLUS_LINE);
00230 assert(fastqfile.myQualityString == EIGHTH_QUALITY);
00231
00232 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00233 assert(fastqfile.mySequenceIdLine == NINTH_SEQID_LINE);
00234 assert(fastqfile.mySequenceIdentifier == NINTH_SEQID);
00235 assert(fastqfile.myRawSequence == NINTH_RAW_SEQ);
00236 assert(fastqfile.myPlusLine == NINTH_PLUS_LINE);
00237 assert(fastqfile.myQualityString == NINTH_QUALITY);
00238
00239 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00240 assert(fastqfile.mySequenceIdLine == TENTH_SEQID_LINE);
00241 assert(fastqfile.mySequenceIdentifier == TENTH_SEQID);
00242 assert(fastqfile.myRawSequence == TENTH_RAW_SEQ);
00243 assert(fastqfile.myPlusLine == TENTH_PLUS_LINE);
00244 assert(fastqfile.myQualityString == TENTH_QUALITY);
00245
00246 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00247 assert(fastqfile.mySequenceIdLine == ELEVENTH_SEQID_LINE);
00248 assert(fastqfile.mySequenceIdentifier == ELEVENTH_SEQID);
00249 assert(fastqfile.myRawSequence == ELEVENTH_RAW_SEQ);
00250 assert(fastqfile.myPlusLine == ELEVENTH_PLUS_LINE);
00251 assert(fastqfile.myQualityString == ELEVENTH_QUALITY);
00252
00253 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00254 assert(fastqfile.mySequenceIdLine == TWELFTH_SEQID_LINE);
00255 assert(fastqfile.mySequenceIdentifier == TWELFTH_SEQID);
00256 assert(fastqfile.myRawSequence == TWELFTH_RAW_SEQ);
00257 assert(fastqfile.myPlusLine == TWELFTH_PLUS_LINE);
00258 assert(fastqfile.myQualityString == TWELFTH_QUALITY);
00259
00260 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00261 assert(fastqfile.mySequenceIdLine == THIRTEENTH_SEQID_LINE);
00262 assert(fastqfile.mySequenceIdentifier == THIRTEENTH_SEQID);
00263 assert(fastqfile.myRawSequence == THIRTEENTH_RAW_SEQ);
00264 assert(fastqfile.myPlusLine == THIRTEENTH_PLUS_LINE);
00265 assert(fastqfile.myQualityString == THIRTEENTH_QUALITY);
00266
00267 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00268 assert(fastqfile.mySequenceIdLine == FOURTEENTH_SEQID_LINE);
00269 assert(fastqfile.mySequenceIdentifier == FOURTEENTH_SEQID);
00270 assert(fastqfile.myRawSequence == FOURTEENTH_RAW_SEQ);
00271 assert(fastqfile.myPlusLine == FOURTEENTH_PLUS_LINE);
00272 assert(fastqfile.myQualityString == FOURTEENTH_QUALITY);
00273
00274 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00275 assert(fastqfile.mySequenceIdLine == FIFTEENTH_SEQID_LINE);
00276 assert(fastqfile.mySequenceIdentifier == FIFTEENTH_SEQID);
00277 assert(fastqfile.myRawSequence == FIFTEENTH_RAW_SEQ);
00278 assert(fastqfile.myPlusLine == FIFTEENTH_PLUS_LINE);
00279 assert(fastqfile.myQualityString == FIFTEENTH_QUALITY);
00280
00281 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00282 assert(fastqfile.mySequenceIdLine == SIXTEENTH_SEQID_LINE);
00283 assert(fastqfile.mySequenceIdentifier == SIXTEENTH_SEQID);
00284 assert(fastqfile.myRawSequence == SIXTEENTH_RAW_SEQ);
00285 assert(fastqfile.myPlusLine == SIXTEENTH_PLUS_LINE);
00286 assert(fastqfile.myQualityString == SIXTEENTH_QUALITY);
00287
00288 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00289 assert(fastqfile.mySequenceIdLine == SEVENTEENTH_SEQID_LINE);
00290 assert(fastqfile.mySequenceIdentifier == SEVENTEENTH_SEQID);
00291 assert(fastqfile.myRawSequence == SEVENTEENTH_RAW_SEQ);
00292 assert(fastqfile.myPlusLine == SEVENTEENTH_PLUS_LINE);
00293 assert(fastqfile.myQualityString == SEVENTEENTH_QUALITY);
00294
00295 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00296 assert(fastqfile.mySequenceIdLine == EIGHTEENTH_SEQID_LINE);
00297 assert(fastqfile.mySequenceIdentifier == EIGHTEENTH_SEQID);
00298 assert(fastqfile.myRawSequence == EIGHTEENTH_RAW_SEQ);
00299 assert(fastqfile.myPlusLine == EIGHTEENTH_PLUS_LINE);
00300 assert(fastqfile.myQualityString == EIGHTEENTH_QUALITY);
00301
00302 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00303 assert(fastqfile.mySequenceIdLine == NINETEENTH_SEQID_LINE);
00304 assert(fastqfile.mySequenceIdentifier == NINETEENTH_SEQID);
00305 assert(fastqfile.myRawSequence == NINETEENTH_RAW_SEQ);
00306 assert(fastqfile.myPlusLine == NINETEENTH_PLUS_LINE);
00307 assert(fastqfile.myQualityString == NINETEENTH_QUALITY);
00308
00309 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00310 assert(fastqfile.mySequenceIdLine == TWENTIETH_SEQID_LINE);
00311 assert(fastqfile.mySequenceIdentifier == TWENTIETH_SEQID);
00312 assert(fastqfile.myRawSequence == TWENTIETH_RAW_SEQ);
00313 assert(fastqfile.myPlusLine == TWENTIETH_PLUS_LINE);
00314 assert(fastqfile.myQualityString == TWENTIETH_QUALITY);
00315
00316 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00317 assert(fastqfile.mySequenceIdLine == TWENTY_FIRST_SEQID_LINE);
00318 assert(fastqfile.mySequenceIdentifier == TWENTY_FIRST_SEQID);
00319 assert(fastqfile.myRawSequence == TWENTY_FIRST_RAW_SEQ);
00320 assert(fastqfile.myPlusLine == TWENTY_FIRST_PLUS_LINE);
00321 assert(fastqfile.myQualityString == TWENTY_FIRST_QUALITY);
00322
00323
00324 assert(fastqfile.closeFile() == FastQStatus::FASTQ_SUCCESS);
00325 assert(fastqfile.isOpen() == false);
00326
00327
00328
00329
00330 assert(fastqfile.isOpen() == false);
00331 assert(fastqfile.openFile("testFile.txt", BaseAsciiMap::BASE_SPACE) == FastQStatus::FASTQ_SUCCESS);
00332
00333 assert(fastqfile.isOpen() == true);
00334
00335 assert(fastqfile.getSpaceType() == BaseAsciiMap::BASE_SPACE);
00336
00337
00338 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00339 assert(fastqfile.mySequenceIdLine == FIRST_SEQID_LINE);
00340 assert(fastqfile.mySequenceIdentifier == FIRST_SEQID);
00341 assert(fastqfile.myRawSequence == FIRST_RAW_SEQ);
00342 assert(fastqfile.myPlusLine == FIRST_PLUS_LINE);
00343 assert(fastqfile.myQualityString == FIRST_QUALITY);
00344 assert(fastqfile.getSpaceType() == BaseAsciiMap::BASE_SPACE);
00345
00346 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00347 assert(fastqfile.mySequenceIdLine == SECOND_SEQID_LINE);
00348 assert(fastqfile.mySequenceIdentifier == SECOND_SEQID);
00349 assert(fastqfile.myRawSequence == SECOND_RAW_SEQ);
00350 assert(fastqfile.myPlusLine == SECOND_PLUS_LINE);
00351 assert(fastqfile.myQualityString == SECOND_QUALITY);
00352
00353 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00354 assert(fastqfile.mySequenceIdLine == THIRD_SEQID_LINE);
00355 assert(fastqfile.mySequenceIdentifier == THIRD_SEQID);
00356 assert(fastqfile.myRawSequence == THIRD_RAW_SEQ);
00357 assert(fastqfile.myPlusLine == THIRD_PLUS_LINE);
00358 assert(fastqfile.myQualityString == THIRD_QUALITY);
00359
00360 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00361 assert(fastqfile.mySequenceIdLine == FOURTH_SEQID_LINE);
00362 assert(fastqfile.mySequenceIdentifier == FOURTH_SEQID);
00363 assert(fastqfile.myRawSequence == FOURTH_RAW_SEQ);
00364 assert(fastqfile.myPlusLine == FOURTH_PLUS_LINE);
00365 assert(fastqfile.myQualityString == FOURTH_QUALITY);
00366
00367 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00368 assert(fastqfile.mySequenceIdLine == FIFTH_SEQID_LINE);
00369 assert(fastqfile.mySequenceIdentifier == FIFTH_SEQID);
00370 assert(fastqfile.myRawSequence == FIFTH_RAW_SEQ);
00371 assert(fastqfile.myPlusLine == FIFTH_PLUS_LINE);
00372 assert(fastqfile.myQualityString == FIFTH_QUALITY);
00373
00374 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00375 assert(fastqfile.mySequenceIdLine == SIXTH_SEQID_LINE);
00376 assert(fastqfile.mySequenceIdentifier == SIXTH_SEQID);
00377 assert(fastqfile.myRawSequence == SIXTH_RAW_SEQ);
00378 assert(fastqfile.myPlusLine == SIXTH_PLUS_LINE);
00379 assert(fastqfile.myQualityString == SIXTH_QUALITY);
00380
00381 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00382 assert(fastqfile.mySequenceIdLine == SEVENTH_SEQID_LINE);
00383 assert(fastqfile.mySequenceIdentifier == SEVENTH_SEQID);
00384 assert(fastqfile.myRawSequence == SEVENTH_RAW_SEQ);
00385 assert(fastqfile.myPlusLine == SEVENTH_PLUS_LINE);
00386 assert(fastqfile.myQualityString == SEVENTH_QUALITY);
00387
00388 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00389 assert(fastqfile.mySequenceIdLine == EIGHTH_SEQID_LINE);
00390 assert(fastqfile.mySequenceIdentifier == EIGHTH_SEQID);
00391 assert(fastqfile.myRawSequence == EIGHTH_RAW_SEQ);
00392 assert(fastqfile.myPlusLine == EIGHTH_PLUS_LINE);
00393 assert(fastqfile.myQualityString == EIGHTH_QUALITY);
00394
00395 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00396 assert(fastqfile.mySequenceIdLine == NINTH_SEQID_LINE);
00397 assert(fastqfile.mySequenceIdentifier == NINTH_SEQID);
00398 assert(fastqfile.myRawSequence == NINTH_RAW_SEQ);
00399 assert(fastqfile.myPlusLine == NINTH_PLUS_LINE);
00400 assert(fastqfile.myQualityString == NINTH_QUALITY);
00401
00402 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00403 assert(fastqfile.mySequenceIdLine == TENTH_SEQID_LINE);
00404 assert(fastqfile.mySequenceIdentifier == TENTH_SEQID);
00405 assert(fastqfile.myRawSequence == TENTH_RAW_SEQ);
00406 assert(fastqfile.myPlusLine == TENTH_PLUS_LINE);
00407 assert(fastqfile.myQualityString == TENTH_QUALITY);
00408
00409 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00410 assert(fastqfile.mySequenceIdLine == ELEVENTH_SEQID_LINE);
00411 assert(fastqfile.mySequenceIdentifier == ELEVENTH_SEQID);
00412 assert(fastqfile.myRawSequence == ELEVENTH_RAW_SEQ);
00413 assert(fastqfile.myPlusLine == ELEVENTH_PLUS_LINE);
00414 assert(fastqfile.myQualityString == ELEVENTH_QUALITY);
00415
00416 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00417 assert(fastqfile.mySequenceIdLine == TWELFTH_SEQID_LINE);
00418 assert(fastqfile.mySequenceIdentifier == TWELFTH_SEQID);
00419 assert(fastqfile.myRawSequence == TWELFTH_RAW_SEQ);
00420 assert(fastqfile.myPlusLine == TWELFTH_PLUS_LINE);
00421 assert(fastqfile.myQualityString == TWELFTH_QUALITY);
00422
00423 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00424 assert(fastqfile.mySequenceIdLine == THIRTEENTH_SEQID_LINE);
00425 assert(fastqfile.mySequenceIdentifier == THIRTEENTH_SEQID);
00426 assert(fastqfile.myRawSequence == THIRTEENTH_RAW_SEQ);
00427 assert(fastqfile.myPlusLine == THIRTEENTH_PLUS_LINE);
00428 assert(fastqfile.myQualityString == THIRTEENTH_QUALITY);
00429
00430 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00431 assert(fastqfile.mySequenceIdLine == FOURTEENTH_SEQID_LINE);
00432 assert(fastqfile.mySequenceIdentifier == FOURTEENTH_SEQID);
00433 assert(fastqfile.myRawSequence == FOURTEENTH_RAW_SEQ);
00434 assert(fastqfile.myPlusLine == FOURTEENTH_PLUS_LINE);
00435 assert(fastqfile.myQualityString == FOURTEENTH_QUALITY);
00436
00437 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00438 assert(fastqfile.mySequenceIdLine == FIFTEENTH_SEQID_LINE);
00439 assert(fastqfile.mySequenceIdentifier == FIFTEENTH_SEQID);
00440 assert(fastqfile.myRawSequence == FIFTEENTH_RAW_SEQ);
00441 assert(fastqfile.myPlusLine == FIFTEENTH_PLUS_LINE);
00442 assert(fastqfile.myQualityString == FIFTEENTH_QUALITY);
00443
00444 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00445 assert(fastqfile.mySequenceIdLine == SIXTEENTH_SEQID_LINE);
00446 assert(fastqfile.mySequenceIdentifier == SIXTEENTH_SEQID);
00447 assert(fastqfile.myRawSequence == SIXTEENTH_RAW_SEQ);
00448 assert(fastqfile.myPlusLine == SIXTEENTH_PLUS_LINE);
00449 assert(fastqfile.myQualityString == SIXTEENTH_QUALITY);
00450
00451 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00452 assert(fastqfile.mySequenceIdLine == SEVENTEENTH_SEQID_LINE);
00453 assert(fastqfile.mySequenceIdentifier == SEVENTEENTH_SEQID);
00454 assert(fastqfile.myRawSequence == SEVENTEENTH_RAW_SEQ);
00455 assert(fastqfile.myPlusLine == SEVENTEENTH_PLUS_LINE);
00456 assert(fastqfile.myQualityString == SEVENTEENTH_QUALITY);
00457
00458 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00459 assert(fastqfile.mySequenceIdLine == EIGHTEENTH_SEQID_LINE);
00460 assert(fastqfile.mySequenceIdentifier == EIGHTEENTH_SEQID);
00461 assert(fastqfile.myRawSequence == EIGHTEENTH_RAW_SEQ);
00462 assert(fastqfile.myPlusLine == EIGHTEENTH_PLUS_LINE);
00463 assert(fastqfile.myQualityString == EIGHTEENTH_QUALITY);
00464
00465 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00466 assert(fastqfile.mySequenceIdLine == NINETEENTH_SEQID_LINE);
00467 assert(fastqfile.mySequenceIdentifier == NINETEENTH_SEQID);
00468 assert(fastqfile.myRawSequence == NINETEENTH_RAW_SEQ);
00469 assert(fastqfile.myPlusLine == NINETEENTH_PLUS_LINE);
00470 assert(fastqfile.myQualityString == NINETEENTH_QUALITY);
00471
00472 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00473 assert(fastqfile.mySequenceIdLine == TWENTIETH_SEQID_LINE);
00474 assert(fastqfile.mySequenceIdentifier == TWENTIETH_SEQID);
00475 assert(fastqfile.myRawSequence == TWENTIETH_RAW_SEQ);
00476 assert(fastqfile.myPlusLine == TWENTIETH_PLUS_LINE);
00477 assert(fastqfile.myQualityString == TWENTIETH_QUALITY);
00478
00479 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00480 assert(fastqfile.mySequenceIdLine == TWENTY_FIRST_SEQID_LINE);
00481 assert(fastqfile.mySequenceIdentifier == TWENTY_FIRST_SEQID);
00482 assert(fastqfile.myRawSequence == TWENTY_FIRST_RAW_SEQ);
00483 assert(fastqfile.myPlusLine == TWENTY_FIRST_PLUS_LINE);
00484 assert(fastqfile.myQualityString == TWENTY_FIRST_QUALITY);
00485
00486
00487 assert(fastqfile.closeFile() == FastQStatus::FASTQ_SUCCESS);
00488 assert(fastqfile.isOpen() == false);
00489
00490
00491
00492
00493 assert(fastqfile.isOpen() == false);
00494 assert(fastqfile.openFile("testFile.txt", BaseAsciiMap::COLOR_SPACE) == FastQStatus::FASTQ_SUCCESS);
00495
00496 assert(fastqfile.isOpen() == true);
00497
00498 assert(fastqfile.getSpaceType() == BaseAsciiMap::COLOR_SPACE);
00499
00500
00501 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00502 assert(fastqfile.mySequenceIdLine == FIRST_SEQID_LINE);
00503 assert(fastqfile.mySequenceIdentifier == FIRST_SEQID);
00504 assert(fastqfile.myRawSequence == FIRST_RAW_SEQ);
00505 assert(fastqfile.myPlusLine == FIRST_PLUS_LINE);
00506 assert(fastqfile.myQualityString == FIRST_QUALITY);
00507 assert(fastqfile.getSpaceType() == BaseAsciiMap::COLOR_SPACE);
00508
00509 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00510 assert(fastqfile.mySequenceIdLine == SECOND_SEQID_LINE);
00511 assert(fastqfile.mySequenceIdentifier == SECOND_SEQID);
00512 assert(fastqfile.myRawSequence == SECOND_RAW_SEQ);
00513 assert(fastqfile.myPlusLine == SECOND_PLUS_LINE);
00514 assert(fastqfile.myQualityString == SECOND_QUALITY);
00515
00516 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00517 assert(fastqfile.mySequenceIdLine == THIRD_SEQID_LINE);
00518 assert(fastqfile.mySequenceIdentifier == THIRD_SEQID);
00519 assert(fastqfile.myRawSequence == THIRD_RAW_SEQ);
00520 assert(fastqfile.myPlusLine == THIRD_PLUS_LINE);
00521 assert(fastqfile.myQualityString == THIRD_QUALITY);
00522
00523 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00524 assert(fastqfile.mySequenceIdLine == FOURTH_SEQID_LINE);
00525 assert(fastqfile.mySequenceIdentifier == FOURTH_SEQID);
00526 assert(fastqfile.myRawSequence == FOURTH_RAW_SEQ);
00527 assert(fastqfile.myPlusLine == FOURTH_PLUS_LINE);
00528 assert(fastqfile.myQualityString == FOURTH_QUALITY);
00529
00530 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00531 assert(fastqfile.mySequenceIdLine == FIFTH_SEQID_LINE);
00532 assert(fastqfile.mySequenceIdentifier == FIFTH_SEQID);
00533 assert(fastqfile.myRawSequence == FIFTH_RAW_SEQ);
00534 assert(fastqfile.myPlusLine == FIFTH_PLUS_LINE);
00535 assert(fastqfile.myQualityString == FIFTH_QUALITY);
00536
00537 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00538 assert(fastqfile.mySequenceIdLine == SIXTH_SEQID_LINE);
00539 assert(fastqfile.mySequenceIdentifier == SIXTH_SEQID);
00540 assert(fastqfile.myRawSequence == SIXTH_RAW_SEQ);
00541 assert(fastqfile.myPlusLine == SIXTH_PLUS_LINE);
00542 assert(fastqfile.myQualityString == SIXTH_QUALITY);
00543
00544 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00545 assert(fastqfile.mySequenceIdLine == SEVENTH_SEQID_LINE);
00546 assert(fastqfile.mySequenceIdentifier == SEVENTH_SEQID);
00547 assert(fastqfile.myRawSequence == SEVENTH_RAW_SEQ);
00548 assert(fastqfile.myPlusLine == SEVENTH_PLUS_LINE);
00549 assert(fastqfile.myQualityString == SEVENTH_QUALITY);
00550
00551 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00552 assert(fastqfile.mySequenceIdLine == EIGHTH_SEQID_LINE);
00553 assert(fastqfile.mySequenceIdentifier == EIGHTH_SEQID);
00554 assert(fastqfile.myRawSequence == EIGHTH_RAW_SEQ);
00555 assert(fastqfile.myPlusLine == EIGHTH_PLUS_LINE);
00556 assert(fastqfile.myQualityString == EIGHTH_QUALITY);
00557
00558 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00559 assert(fastqfile.mySequenceIdLine == NINTH_SEQID_LINE);
00560 assert(fastqfile.mySequenceIdentifier == NINTH_SEQID);
00561 assert(fastqfile.myRawSequence == NINTH_RAW_SEQ);
00562 assert(fastqfile.myPlusLine == NINTH_PLUS_LINE);
00563 assert(fastqfile.myQualityString == NINTH_QUALITY);
00564
00565 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00566 assert(fastqfile.mySequenceIdLine == TENTH_SEQID_LINE);
00567 assert(fastqfile.mySequenceIdentifier == TENTH_SEQID);
00568 assert(fastqfile.myRawSequence == TENTH_RAW_SEQ);
00569 assert(fastqfile.myPlusLine == TENTH_PLUS_LINE);
00570 assert(fastqfile.myQualityString == TENTH_QUALITY);
00571
00572 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00573 assert(fastqfile.mySequenceIdLine == ELEVENTH_SEQID_LINE);
00574 assert(fastqfile.mySequenceIdentifier == ELEVENTH_SEQID);
00575 assert(fastqfile.myRawSequence == ELEVENTH_RAW_SEQ);
00576 assert(fastqfile.myPlusLine == ELEVENTH_PLUS_LINE);
00577 assert(fastqfile.myQualityString == ELEVENTH_QUALITY);
00578
00579 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00580 assert(fastqfile.mySequenceIdLine == TWELFTH_SEQID_LINE);
00581 assert(fastqfile.mySequenceIdentifier == TWELFTH_SEQID);
00582 assert(fastqfile.myRawSequence == TWELFTH_RAW_SEQ);
00583 assert(fastqfile.myPlusLine == TWELFTH_PLUS_LINE);
00584 assert(fastqfile.myQualityString == TWELFTH_QUALITY);
00585
00586 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00587 assert(fastqfile.mySequenceIdLine == THIRTEENTH_SEQID_LINE);
00588 assert(fastqfile.mySequenceIdentifier == THIRTEENTH_SEQID);
00589 assert(fastqfile.myRawSequence == THIRTEENTH_RAW_SEQ);
00590 assert(fastqfile.myPlusLine == THIRTEENTH_PLUS_LINE);
00591 assert(fastqfile.myQualityString == THIRTEENTH_QUALITY);
00592
00593 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00594 assert(fastqfile.mySequenceIdLine == FOURTEENTH_SEQID_LINE);
00595 assert(fastqfile.mySequenceIdentifier == FOURTEENTH_SEQID);
00596 assert(fastqfile.myRawSequence == FOURTEENTH_RAW_SEQ);
00597 assert(fastqfile.myPlusLine == FOURTEENTH_PLUS_LINE);
00598 assert(fastqfile.myQualityString == FOURTEENTH_QUALITY);
00599
00600 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00601 assert(fastqfile.mySequenceIdLine == FIFTEENTH_SEQID_LINE);
00602 assert(fastqfile.mySequenceIdentifier == FIFTEENTH_SEQID);
00603 assert(fastqfile.myRawSequence == FIFTEENTH_RAW_SEQ);
00604 assert(fastqfile.myPlusLine == FIFTEENTH_PLUS_LINE);
00605 assert(fastqfile.myQualityString == FIFTEENTH_QUALITY);
00606
00607 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00608 assert(fastqfile.mySequenceIdLine == SIXTEENTH_SEQID_LINE);
00609 assert(fastqfile.mySequenceIdentifier == SIXTEENTH_SEQID);
00610 assert(fastqfile.myRawSequence == SIXTEENTH_RAW_SEQ);
00611 assert(fastqfile.myPlusLine == SIXTEENTH_PLUS_LINE);
00612 assert(fastqfile.myQualityString == SIXTEENTH_QUALITY);
00613
00614 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00615 assert(fastqfile.mySequenceIdLine == SEVENTEENTH_SEQID_LINE);
00616 assert(fastqfile.mySequenceIdentifier == SEVENTEENTH_SEQID);
00617 assert(fastqfile.myRawSequence == SEVENTEENTH_RAW_SEQ);
00618 assert(fastqfile.myPlusLine == SEVENTEENTH_PLUS_LINE);
00619 assert(fastqfile.myQualityString == SEVENTEENTH_QUALITY);
00620
00621 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00622 assert(fastqfile.mySequenceIdLine == EIGHTEENTH_SEQID_LINE);
00623 assert(fastqfile.mySequenceIdentifier == EIGHTEENTH_SEQID);
00624 assert(fastqfile.myRawSequence == EIGHTEENTH_RAW_SEQ);
00625 assert(fastqfile.myPlusLine == EIGHTEENTH_PLUS_LINE);
00626 assert(fastqfile.myQualityString == EIGHTEENTH_QUALITY);
00627
00628 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00629 assert(fastqfile.mySequenceIdLine == NINETEENTH_SEQID_LINE);
00630 assert(fastqfile.mySequenceIdentifier == NINETEENTH_SEQID);
00631 assert(fastqfile.myRawSequence == NINETEENTH_RAW_SEQ);
00632 assert(fastqfile.myPlusLine == NINETEENTH_PLUS_LINE);
00633 assert(fastqfile.myQualityString == NINETEENTH_QUALITY);
00634
00635 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00636 assert(fastqfile.mySequenceIdLine == TWENTIETH_SEQID_LINE);
00637 assert(fastqfile.mySequenceIdentifier == TWENTIETH_SEQID);
00638 assert(fastqfile.myRawSequence == TWENTIETH_RAW_SEQ);
00639 assert(fastqfile.myPlusLine == TWENTIETH_PLUS_LINE);
00640 assert(fastqfile.myQualityString == TWENTIETH_QUALITY);
00641
00642 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00643 assert(fastqfile.mySequenceIdLine == TWENTY_FIRST_SEQID_LINE);
00644 assert(fastqfile.mySequenceIdentifier == TWENTY_FIRST_SEQID);
00645 assert(fastqfile.myRawSequence == TWENTY_FIRST_RAW_SEQ);
00646 assert(fastqfile.myPlusLine == TWENTY_FIRST_PLUS_LINE);
00647 assert(fastqfile.myQualityString == TWENTY_FIRST_QUALITY);
00648
00649
00650 assert(fastqfile.closeFile() == FastQStatus::FASTQ_SUCCESS);
00651 assert(fastqfile.isOpen() == false);
00652
00653
00654
00655 assert(fastqfile.isOpen() == false);
00656 assert(fastqfile.openFile("testFile.txt", BaseAsciiMap::UNKNOWN) == FastQStatus::FASTQ_SUCCESS);
00657
00658 assert(fastqfile.isOpen() == true);
00659
00660 assert(fastqfile.getSpaceType() == BaseAsciiMap::UNKNOWN);
00661
00662
00663 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00664 assert(fastqfile.mySequenceIdLine == FIRST_SEQID_LINE);
00665 assert(fastqfile.mySequenceIdentifier == FIRST_SEQID);
00666 assert(fastqfile.myRawSequence == FIRST_RAW_SEQ);
00667 assert(fastqfile.myPlusLine == FIRST_PLUS_LINE);
00668 assert(fastqfile.myQualityString == FIRST_QUALITY);
00669 assert(fastqfile.getSpaceType() == BaseAsciiMap::BASE_SPACE);
00670
00671 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00672 assert(fastqfile.mySequenceIdLine == SECOND_SEQID_LINE);
00673 assert(fastqfile.mySequenceIdentifier == SECOND_SEQID);
00674 assert(fastqfile.myRawSequence == SECOND_RAW_SEQ);
00675 assert(fastqfile.myPlusLine == SECOND_PLUS_LINE);
00676 assert(fastqfile.myQualityString == SECOND_QUALITY);
00677
00678 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00679 assert(fastqfile.mySequenceIdLine == THIRD_SEQID_LINE);
00680 assert(fastqfile.mySequenceIdentifier == THIRD_SEQID);
00681 assert(fastqfile.myRawSequence == THIRD_RAW_SEQ);
00682 assert(fastqfile.myPlusLine == THIRD_PLUS_LINE);
00683 assert(fastqfile.myQualityString == THIRD_QUALITY);
00684
00685 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00686 assert(fastqfile.mySequenceIdLine == FOURTH_SEQID_LINE);
00687 assert(fastqfile.mySequenceIdentifier == FOURTH_SEQID);
00688 assert(fastqfile.myRawSequence == FOURTH_RAW_SEQ);
00689 assert(fastqfile.myPlusLine == FOURTH_PLUS_LINE);
00690 assert(fastqfile.myQualityString == FOURTH_QUALITY);
00691
00692 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00693 assert(fastqfile.mySequenceIdLine == FIFTH_SEQID_LINE);
00694 assert(fastqfile.mySequenceIdentifier == FIFTH_SEQID);
00695 assert(fastqfile.myRawSequence == FIFTH_RAW_SEQ);
00696 assert(fastqfile.myPlusLine == FIFTH_PLUS_LINE);
00697 assert(fastqfile.myQualityString == FIFTH_QUALITY);
00698
00699 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00700 assert(fastqfile.mySequenceIdLine == SIXTH_SEQID_LINE);
00701 assert(fastqfile.mySequenceIdentifier == SIXTH_SEQID);
00702 assert(fastqfile.myRawSequence == SIXTH_RAW_SEQ);
00703 assert(fastqfile.myPlusLine == SIXTH_PLUS_LINE);
00704 assert(fastqfile.myQualityString == SIXTH_QUALITY);
00705
00706 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00707 assert(fastqfile.mySequenceIdLine == SEVENTH_SEQID_LINE);
00708 assert(fastqfile.mySequenceIdentifier == SEVENTH_SEQID);
00709 assert(fastqfile.myRawSequence == SEVENTH_RAW_SEQ);
00710 assert(fastqfile.myPlusLine == SEVENTH_PLUS_LINE);
00711 assert(fastqfile.myQualityString == SEVENTH_QUALITY);
00712
00713 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00714 assert(fastqfile.mySequenceIdLine == EIGHTH_SEQID_LINE);
00715 assert(fastqfile.mySequenceIdentifier == EIGHTH_SEQID);
00716 assert(fastqfile.myRawSequence == EIGHTH_RAW_SEQ);
00717 assert(fastqfile.myPlusLine == EIGHTH_PLUS_LINE);
00718 assert(fastqfile.myQualityString == EIGHTH_QUALITY);
00719
00720 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00721 assert(fastqfile.mySequenceIdLine == NINTH_SEQID_LINE);
00722 assert(fastqfile.mySequenceIdentifier == NINTH_SEQID);
00723 assert(fastqfile.myRawSequence == NINTH_RAW_SEQ);
00724 assert(fastqfile.myPlusLine == NINTH_PLUS_LINE);
00725 assert(fastqfile.myQualityString == NINTH_QUALITY);
00726
00727 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00728 assert(fastqfile.mySequenceIdLine == TENTH_SEQID_LINE);
00729 assert(fastqfile.mySequenceIdentifier == TENTH_SEQID);
00730 assert(fastqfile.myRawSequence == TENTH_RAW_SEQ);
00731 assert(fastqfile.myPlusLine == TENTH_PLUS_LINE);
00732 assert(fastqfile.myQualityString == TENTH_QUALITY);
00733
00734 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00735 assert(fastqfile.mySequenceIdLine == ELEVENTH_SEQID_LINE);
00736 assert(fastqfile.mySequenceIdentifier == ELEVENTH_SEQID);
00737 assert(fastqfile.myRawSequence == ELEVENTH_RAW_SEQ);
00738 assert(fastqfile.myPlusLine == ELEVENTH_PLUS_LINE);
00739 assert(fastqfile.myQualityString == ELEVENTH_QUALITY);
00740
00741 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00742 assert(fastqfile.mySequenceIdLine == TWELFTH_SEQID_LINE);
00743 assert(fastqfile.mySequenceIdentifier == TWELFTH_SEQID);
00744 assert(fastqfile.myRawSequence == TWELFTH_RAW_SEQ);
00745 assert(fastqfile.myPlusLine == TWELFTH_PLUS_LINE);
00746 assert(fastqfile.myQualityString == TWELFTH_QUALITY);
00747
00748 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00749 assert(fastqfile.mySequenceIdLine == THIRTEENTH_SEQID_LINE);
00750 assert(fastqfile.mySequenceIdentifier == THIRTEENTH_SEQID);
00751 assert(fastqfile.myRawSequence == THIRTEENTH_RAW_SEQ);
00752 assert(fastqfile.myPlusLine == THIRTEENTH_PLUS_LINE);
00753 assert(fastqfile.myQualityString == THIRTEENTH_QUALITY);
00754
00755 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00756 assert(fastqfile.mySequenceIdLine == FOURTEENTH_SEQID_LINE);
00757 assert(fastqfile.mySequenceIdentifier == FOURTEENTH_SEQID);
00758 assert(fastqfile.myRawSequence == FOURTEENTH_RAW_SEQ);
00759 assert(fastqfile.myPlusLine == FOURTEENTH_PLUS_LINE);
00760 assert(fastqfile.myQualityString == FOURTEENTH_QUALITY);
00761
00762 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00763 assert(fastqfile.mySequenceIdLine == FIFTEENTH_SEQID_LINE);
00764 assert(fastqfile.mySequenceIdentifier == FIFTEENTH_SEQID);
00765 assert(fastqfile.myRawSequence == FIFTEENTH_RAW_SEQ);
00766 assert(fastqfile.myPlusLine == FIFTEENTH_PLUS_LINE);
00767 assert(fastqfile.myQualityString == FIFTEENTH_QUALITY);
00768
00769 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00770 assert(fastqfile.mySequenceIdLine == SIXTEENTH_SEQID_LINE);
00771 assert(fastqfile.mySequenceIdentifier == SIXTEENTH_SEQID);
00772 assert(fastqfile.myRawSequence == SIXTEENTH_RAW_SEQ);
00773 assert(fastqfile.myPlusLine == SIXTEENTH_PLUS_LINE);
00774 assert(fastqfile.myQualityString == SIXTEENTH_QUALITY);
00775
00776 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00777 assert(fastqfile.mySequenceIdLine == SEVENTEENTH_SEQID_LINE);
00778 assert(fastqfile.mySequenceIdentifier == SEVENTEENTH_SEQID);
00779 assert(fastqfile.myRawSequence == SEVENTEENTH_RAW_SEQ);
00780 assert(fastqfile.myPlusLine == SEVENTEENTH_PLUS_LINE);
00781 assert(fastqfile.myQualityString == SEVENTEENTH_QUALITY);
00782
00783 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00784 assert(fastqfile.mySequenceIdLine == EIGHTEENTH_SEQID_LINE);
00785 assert(fastqfile.mySequenceIdentifier == EIGHTEENTH_SEQID);
00786 assert(fastqfile.myRawSequence == EIGHTEENTH_RAW_SEQ);
00787 assert(fastqfile.myPlusLine == EIGHTEENTH_PLUS_LINE);
00788 assert(fastqfile.myQualityString == EIGHTEENTH_QUALITY);
00789
00790 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00791 assert(fastqfile.mySequenceIdLine == NINETEENTH_SEQID_LINE);
00792 assert(fastqfile.mySequenceIdentifier == NINETEENTH_SEQID);
00793 assert(fastqfile.myRawSequence == NINETEENTH_RAW_SEQ);
00794 assert(fastqfile.myPlusLine == NINETEENTH_PLUS_LINE);
00795 assert(fastqfile.myQualityString == NINETEENTH_QUALITY);
00796
00797 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00798 assert(fastqfile.mySequenceIdLine == TWENTIETH_SEQID_LINE);
00799 assert(fastqfile.mySequenceIdentifier == TWENTIETH_SEQID);
00800 assert(fastqfile.myRawSequence == TWENTIETH_RAW_SEQ);
00801 assert(fastqfile.myPlusLine == TWENTIETH_PLUS_LINE);
00802 assert(fastqfile.myQualityString == TWENTIETH_QUALITY);
00803
00804 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00805 assert(fastqfile.mySequenceIdLine == TWENTY_FIRST_SEQID_LINE);
00806 assert(fastqfile.mySequenceIdentifier == TWENTY_FIRST_SEQID);
00807 assert(fastqfile.myRawSequence == TWENTY_FIRST_RAW_SEQ);
00808 assert(fastqfile.myPlusLine == TWENTY_FIRST_PLUS_LINE);
00809 assert(fastqfile.myQualityString == TWENTY_FIRST_QUALITY);
00810
00811
00812 assert(fastqfile.closeFile() == FastQStatus::FASTQ_SUCCESS);
00813 assert(fastqfile.isOpen() == false);
00814
00815
00816
00817
00818 fastqfile.disableSeqIDCheck();
00819 assert(fastqfile.isOpen() == false);
00820 assert(fastqfile.openFile("testFile.txt", BaseAsciiMap::UNKNOWN) == FastQStatus::FASTQ_SUCCESS);
00821
00822 assert(fastqfile.isOpen() == true);
00823
00824 assert(fastqfile.getSpaceType() == BaseAsciiMap::UNKNOWN);
00825
00826
00827 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00828 assert(fastqfile.mySequenceIdLine == FIRST_SEQID_LINE);
00829 assert(fastqfile.mySequenceIdentifier == FIRST_SEQID);
00830 assert(fastqfile.myRawSequence == FIRST_RAW_SEQ);
00831 assert(fastqfile.myPlusLine == FIRST_PLUS_LINE);
00832 assert(fastqfile.myQualityString == FIRST_QUALITY);
00833 assert(fastqfile.getSpaceType() == BaseAsciiMap::BASE_SPACE);
00834
00835 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00836 assert(fastqfile.mySequenceIdLine == SECOND_SEQID_LINE);
00837 assert(fastqfile.mySequenceIdentifier == SECOND_SEQID);
00838 assert(fastqfile.myRawSequence == SECOND_RAW_SEQ);
00839 assert(fastqfile.myPlusLine == SECOND_PLUS_LINE);
00840 assert(fastqfile.myQualityString == SECOND_QUALITY);
00841
00842 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00843 assert(fastqfile.mySequenceIdLine == THIRD_SEQID_LINE);
00844 assert(fastqfile.mySequenceIdentifier == THIRD_SEQID);
00845 assert(fastqfile.myRawSequence == THIRD_RAW_SEQ);
00846 assert(fastqfile.myPlusLine == THIRD_PLUS_LINE);
00847 assert(fastqfile.myQualityString == THIRD_QUALITY);
00848
00849 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00850 assert(fastqfile.mySequenceIdLine == FOURTH_SEQID_LINE);
00851 assert(fastqfile.mySequenceIdentifier == FOURTH_SEQID);
00852 assert(fastqfile.myRawSequence == FOURTH_RAW_SEQ);
00853 assert(fastqfile.myPlusLine == FOURTH_PLUS_LINE);
00854 assert(fastqfile.myQualityString == FOURTH_QUALITY);
00855
00856 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00857 assert(fastqfile.mySequenceIdLine == FIFTH_SEQID_LINE);
00858 assert(fastqfile.mySequenceIdentifier == FIFTH_SEQID);
00859 assert(fastqfile.myRawSequence == FIFTH_RAW_SEQ);
00860 assert(fastqfile.myPlusLine == FIFTH_PLUS_LINE);
00861 assert(fastqfile.myQualityString == FIFTH_QUALITY);
00862
00863 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00864 assert(fastqfile.mySequenceIdLine == SIXTH_SEQID_LINE);
00865 assert(fastqfile.mySequenceIdentifier == SIXTH_SEQID);
00866 assert(fastqfile.myRawSequence == SIXTH_RAW_SEQ);
00867 assert(fastqfile.myPlusLine == SIXTH_PLUS_LINE);
00868 assert(fastqfile.myQualityString == SIXTH_QUALITY);
00869
00870 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00871 assert(fastqfile.mySequenceIdLine == SEVENTH_SEQID_LINE);
00872 assert(fastqfile.mySequenceIdentifier == SEVENTH_SEQID);
00873 assert(fastqfile.myRawSequence == SEVENTH_RAW_SEQ);
00874 assert(fastqfile.myPlusLine == SEVENTH_PLUS_LINE);
00875 assert(fastqfile.myQualityString == SEVENTH_QUALITY);
00876
00877 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00878 assert(fastqfile.mySequenceIdLine == EIGHTH_SEQID_LINE);
00879 assert(fastqfile.mySequenceIdentifier == EIGHTH_SEQID);
00880 assert(fastqfile.myRawSequence == EIGHTH_RAW_SEQ);
00881 assert(fastqfile.myPlusLine == EIGHTH_PLUS_LINE);
00882 assert(fastqfile.myQualityString == EIGHTH_QUALITY);
00883
00884 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00885 assert(fastqfile.mySequenceIdLine == NINTH_SEQID_LINE);
00886 assert(fastqfile.mySequenceIdentifier == NINTH_SEQID);
00887 assert(fastqfile.myRawSequence == NINTH_RAW_SEQ);
00888 assert(fastqfile.myPlusLine == NINTH_PLUS_LINE);
00889 assert(fastqfile.myQualityString == NINTH_QUALITY);
00890
00891 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00892 assert(fastqfile.mySequenceIdLine == TENTH_SEQID_LINE);
00893 assert(fastqfile.mySequenceIdentifier == TENTH_SEQID);
00894 assert(fastqfile.myRawSequence == TENTH_RAW_SEQ);
00895 assert(fastqfile.myPlusLine == TENTH_PLUS_LINE);
00896 assert(fastqfile.myQualityString == TENTH_QUALITY);
00897
00898 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00899 assert(fastqfile.mySequenceIdLine == ELEVENTH_SEQID_LINE);
00900 assert(fastqfile.mySequenceIdentifier == ELEVENTH_SEQID);
00901 assert(fastqfile.myRawSequence == ELEVENTH_RAW_SEQ);
00902 assert(fastqfile.myPlusLine == ELEVENTH_PLUS_LINE);
00903 assert(fastqfile.myQualityString == ELEVENTH_QUALITY);
00904
00905 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00906 assert(fastqfile.mySequenceIdLine == TWELFTH_SEQID_LINE);
00907 assert(fastqfile.mySequenceIdentifier == TWELFTH_SEQID);
00908 assert(fastqfile.myRawSequence == TWELFTH_RAW_SEQ);
00909 assert(fastqfile.myPlusLine == TWELFTH_PLUS_LINE);
00910 assert(fastqfile.myQualityString == TWELFTH_QUALITY);
00911
00912 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00913 assert(fastqfile.mySequenceIdLine == THIRTEENTH_SEQID_LINE);
00914 assert(fastqfile.mySequenceIdentifier == THIRTEENTH_SEQID);
00915 assert(fastqfile.myRawSequence == THIRTEENTH_RAW_SEQ);
00916 assert(fastqfile.myPlusLine == THIRTEENTH_PLUS_LINE);
00917 assert(fastqfile.myQualityString == THIRTEENTH_QUALITY);
00918
00919 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00920 assert(fastqfile.mySequenceIdLine == FOURTEENTH_SEQID_LINE);
00921 assert(fastqfile.mySequenceIdentifier == FOURTEENTH_SEQID);
00922 assert(fastqfile.myRawSequence == FOURTEENTH_RAW_SEQ);
00923 assert(fastqfile.myPlusLine == FOURTEENTH_PLUS_LINE);
00924 assert(fastqfile.myQualityString == FOURTEENTH_QUALITY);
00925
00926 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00927 assert(fastqfile.mySequenceIdLine == FIFTEENTH_SEQID_LINE);
00928 assert(fastqfile.mySequenceIdentifier == FIFTEENTH_SEQID);
00929 assert(fastqfile.myRawSequence == FIFTEENTH_RAW_SEQ);
00930 assert(fastqfile.myPlusLine == FIFTEENTH_PLUS_LINE);
00931 assert(fastqfile.myQualityString == FIFTEENTH_QUALITY);
00932
00933 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00934 assert(fastqfile.mySequenceIdLine == SIXTEENTH_SEQID_LINE);
00935 assert(fastqfile.mySequenceIdentifier == SIXTEENTH_SEQID);
00936 assert(fastqfile.myRawSequence == SIXTEENTH_RAW_SEQ);
00937 assert(fastqfile.myPlusLine == SIXTEENTH_PLUS_LINE);
00938 assert(fastqfile.myQualityString == SIXTEENTH_QUALITY);
00939
00940 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00941 assert(fastqfile.mySequenceIdLine == SEVENTEENTH_SEQID_LINE);
00942 assert(fastqfile.mySequenceIdentifier == SEVENTEENTH_SEQID);
00943 assert(fastqfile.myRawSequence == SEVENTEENTH_RAW_SEQ);
00944 assert(fastqfile.myPlusLine == SEVENTEENTH_PLUS_LINE);
00945 assert(fastqfile.myQualityString == SEVENTEENTH_QUALITY);
00946
00947 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_SUCCESS);
00948 assert(fastqfile.mySequenceIdLine == EIGHTEENTH_SEQID_LINE);
00949 assert(fastqfile.mySequenceIdentifier == EIGHTEENTH_SEQID);
00950 assert(fastqfile.myRawSequence == EIGHTEENTH_RAW_SEQ);
00951 assert(fastqfile.myPlusLine == EIGHTEENTH_PLUS_LINE);
00952 assert(fastqfile.myQualityString == EIGHTEENTH_QUALITY);
00953
00954 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00955 assert(fastqfile.mySequenceIdLine == NINETEENTH_SEQID_LINE);
00956 assert(fastqfile.mySequenceIdentifier == NINETEENTH_SEQID);
00957 assert(fastqfile.myRawSequence == NINETEENTH_RAW_SEQ);
00958 assert(fastqfile.myPlusLine == NINETEENTH_PLUS_LINE);
00959 assert(fastqfile.myQualityString == NINETEENTH_QUALITY);
00960
00961 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00962 assert(fastqfile.mySequenceIdLine == TWENTIETH_SEQID_LINE);
00963 assert(fastqfile.mySequenceIdentifier == TWENTIETH_SEQID);
00964 assert(fastqfile.myRawSequence == TWENTIETH_RAW_SEQ);
00965 assert(fastqfile.myPlusLine == TWENTIETH_PLUS_LINE);
00966 assert(fastqfile.myQualityString == TWENTIETH_QUALITY);
00967
00968 assert(fastqfile.readFastQSequence() == FastQStatus::FASTQ_INVALID);
00969 assert(fastqfile.mySequenceIdLine == TWENTY_FIRST_SEQID_LINE);
00970 assert(fastqfile.mySequenceIdentifier == TWENTY_FIRST_SEQID);
00971 assert(fastqfile.myRawSequence == TWENTY_FIRST_RAW_SEQ);
00972 assert(fastqfile.myPlusLine == TWENTY_FIRST_PLUS_LINE);
00973 assert(fastqfile.myQualityString == TWENTY_FIRST_QUALITY);
00974
00975
00976 assert(fastqfile.closeFile() == FastQStatus::FASTQ_SUCCESS);
00977 assert(fastqfile.isOpen() == false);
00978
00979
00980 }
00981
00982 int main(int argc, char ** argv)
00983 {
00984 testReadUnOpenedFile();
00985 testOpenFile();
00986 testCloseFile();
00987 testReadSequence();
00988 }
00989