BOOST_REQUIRE(instream);
92 while(!line_reader.
AtEOF()) {
98 "Could not retrieve seq entry");
107 stringseqInputData = (isNuc) ? kNuclSeqs :
kProtSeqs;
108 boolparse_id = (isNuc) ?
false:
true;
111x_LoadSequences(seqInputData, parse_id);
116kNuclSeqs =
"data/nucleotide.fa";
118kNucleotide_seqalign =
"data/multialign_nucleotide.asn";
119kProtein_seqalign =
"data/multialign.asn";
138 stringseqalign_file = (isNuc) ? kNucleotide_seqalign : kProtein_seqalign;
149printer.
Print(output_stream);
170BOOST_REQUIRE(
output.find(
">gi|129295|sp|P01013.1|OVALX_CHICK RecName: " 171 "Full=Ovalbumin-related protein X; AltName: " 172 "Full=Gene X protein") !=
NPOS);
173BOOST_REQUIRE(
output.find(
"--------------------------------MPQWANPVPAIA--G" 174 "AAPVVITSARAAISAGVDEA---GALGTSAAVP") !=
NPOS);
177BOOST_REQUIRE(
output.find(
"KTG------LLLAAGLIGDPLLAGE----") !=
NPOS);
184BOOST_REQUIRE(
output.find(
">lcl|1 gi|405832|gb|U00001.1|HSCDC27 Human " 185 "homologue of S. pombe nuc2+ and A. nidulans " 188BOOST_REQUIRE(
output.find(
"CACTAATACACCTCCTGTAATTGATGTGCCATCCACCGGAGCCCCT" 189 "TC-------AA-A-------A-------------") !=
NPOS);
192BOOST_REQUIRE(
output.find(
"GATGAATTTTAACTTCTGGAAATCAGACTTTTACAACTGGATGTGT" 193 "GACTAGTGCTGACATGTTTCT-------") !=
NPOS);
203BOOST_REQUIRE(
output.find(
"gi|189500654 M----------------" 204 "------------------------RII-IYNR---------------" 205 "----------------") !=
NPOS);
207BOOST_REQUIRE(
output.find(
"gi|125972714 VMHSYNILWGESSKQISE" 208 "GIS-EVVYRTELTGLEPNT---EYTYKI----YGQMPIRNKEGTPETI" 209 "TFKTLPKKLVYGEL") !=
NPOS);
218BOOST_REQUIRE(
output.find(
"lcl|2 ------CCGCTACAGG" 219 "GGGGGCCTGAGGCACTGCAGAAAGTGGGCCTGAGCCTCGAGGATGA" 222BOOST_REQUIRE(
output.find(
" " 227BOOST_REQUIRE(
output.find(
"lcl|10 GATGAATTTTAACTTC" 228 "TGGAAATCAGACTTTTACAACTGGATGTG") !=
NPOS);
238BOOST_REQUIRE(
output.find(
" 100 749") !=
NPOS);
240BOOST_REQUIRE(
output.find(
"RecName__ ---------------------------") !=
NPOS);
241BOOST_REQUIRE(
output.find(
"-----------------------------------------------" 242 "----------QIKDLLVSSSTD-LDTTLVLVNA") !=
NPOS);
245BOOST_REQUIRE(
output.find(
"ARFAFALRDTKTG------LLLAAGLIGDPLLAGE----")
253BOOST_REQUIRE(
output.find(
" 10 2634") !=
NPOS);
255BOOST_REQUIRE(
output.find(
"gi_167466 ------CCGCTACAGGGGGGGCCTGAGGCACTGCAG" 256 "AAAGTGGGCCTGAGCCTCGAGGATGACGGTGCTG") !=
NPOS);
259BOOST_REQUIRE(
output.find(
"AGCTGAAAGTGATGAATTTTAACTTCTGGAAATCAGACTTTTACAA" 260 "CTGGATGTGTGACTAGTGCTGACATGTTTCT---") !=
NPOS);
270BOOST_REQUIRE(
output.find(
" 100 749") !=
NPOS);
272BOOST_REQUIRE(
output.find(
"RecName__ -------------------------------------" 273 "----------------------------------") !=
NPOS);
276BOOST_REQUIRE(
output.find(
"serine__o --------------------------------MPQWA" 277 "NPVPAIA--GAAPVVITSARAAISAGVDEA---G") !=
NPOS);
280BOOST_REQUIRE(
output.find(
"DTKTG------LLLAAGLIGDPLLAGE----") !=
NPOS);
287BOOST_REQUIRE(
output.find(
" 10 2634") !=
NPOS);
289BOOST_REQUIRE(
output.find(
"gi_167466 ------CCGCTACAGGGGGGGCCTGAGGCACTGCAG" 290 "AAAGTGGGCCTGAGCCTCGAGGATGACGGTGCTGC") !=
NPOS);
293BOOST_REQUIRE(
output.find(
"ATCAGACTTTTACAACTGGATGTGTGACTAGTGCTGACATGTTTCT" 294 "-------") !=
NPOS);
305BOOST_REQUIRE(
output.find(
"#NEXUS") !=
NPOS);
306BOOST_REQUIRE(
output.find(
"BEGIN DATA;") !=
NPOS);
307BOOST_REQUIRE(
output.find(
"DIMENSIONS ntax=100 nchar=749;") !=
NPOS);
308BOOST_REQUIRE(
output.find(
"FORMAT datatype=protein gap=- interleave;")
310BOOST_REQUIRE(
output.find(
"MATRIX") !=
NPOS);
313BOOST_REQUIRE(
output.find(
"129295 -----------------------------------" 314 "----------------------------------------------")
318BOOST_REQUIRE(
output.find(
"162452372 --------------------------------MPQW" 319 "ANPVPAIA--GAAPVVITSARAAISAGVDEA---GALGTSAAVPG")
324BOOST_REQUIRE(
output.find(
"241667095 LLLAAGLIGDPLLAGE----\n\n;") !=
NPOS 327 output.find(
"241667095 LLLAAGLIGDPLLAGE----\r\n\r\n;")
329BOOST_REQUIRE(
output.find(
"END;") !=
NPOS);
337BOOST_REQUIRE(
output.find(
"#NEXUS") !=
NPOS);
338BOOST_REQUIRE(
output.find(
"BEGIN DATA;") !=
NPOS);
339BOOST_REQUIRE(
output.find(
"DIMENSIONS ntax=10 nchar=2634;") !=
NPOS);
340BOOST_REQUIRE(
output.find(
"FORMAT datatype=dna gap=- interleave;") !=
NPOS);
341BOOST_REQUIRE(
output.find(
"MATRIX") !=
NPOS);
343BOOST_REQUIRE(
output.find(
"2 ------CCGCTACAGGGGGGGCCTGAGGCACTGCAGAAAGTG" 344 "GGCCTGAGCCTCGAGGATGACGGTGCTGCAGGAACCCGT") !=
NPOS);
346BOOST_REQUIRE(
output.find(
"4 CCAGGCTGCTATATGGCAAGCACTAAACCACTATGCTTACCG" 347 "AGATGCGGTTTTCCTCGCAGAACGCCTTTATGCAGAAGT") !=
NPOS);
351BOOST_REQUIRE(
output.find(
"10 ACAACTGGATGTGTGACTAGTGCTGACATGTTTCT-------\n\n;")
354 output.find(
"10 ACAACTGGATGTGTGACTAGTGCTGACATGTTTCT-------\r\n\r\n;")
356BOOST_REQUIRE(
output.find(
"END;") !=
NPOS);
static CRef< CScope > m_Scope
BOOST_AUTO_TEST_CASE(TestFastaPlusGaps)
BOOST_AUTO_TEST_SUITE_END() static int s_GetSegmentFlags(const CBioseq &bioseq)
string kNucleotide_seqalign
CRef< CObjectManager > m_Objmgr
void x_LoadSequences(const string &filename, bool parse_id)
string PrintAlignment(CMultiAlnPrinter::EFormat format, bool isNuc, CMultiAlnPrinter::EAlignType type=CMultiAlnPrinter::eNotSet)
Base class for reading FASTA sequences.
Printer for popular multiple alignmnet formats.
EAlignType
Alignment display type for showing nucleotice or protein-related information.
void Print(CNcbiOstream &ostr)
Print alignment.
EFormat
Multiple alignmnet text formats.
void SetFormat(EFormat format)
Set format for printing alignment.
void SetWidth(int width)
Set text width (number of columns) for alignment output.
CNcbiOstrstreamToString class helps convert CNcbiOstrstream to a string Sample usage:
Simple implementation of ILineReader for i(o)streams.
Template class for iteration on objects of class C (non-medifiable version)
@ eProblem_ModifierFoundButNoneExpected
Operators to edit gaps in sequences.
static SQLCHAR output[256]
#define NCBI_THROW(exception_class, err_code, message)
Generic macro to throw an exception, given the exception class, error code and message string.
#define MSerial_AsnText
I/O stream manipulators â.
virtual CRef< CSeq_entry > ReadOneSeq(ILineErrorListener *pMessageListener=nullptr)
Read a single effective sequence, which may turn out to be a segmented set.
long TFlags
binary OR of EFlags
bool AtEOF(void) const
Indicates (negatively) whether there is any more input.
void IgnoreProblem(ILineError::EProblem problem)
@ fNoParseID
Generate an ID (whole defline -> title)
CConstBeginInfo ConstBegin(const C &obj)
Get starting point of non-modifiable object hierarchy.
static CRef< CObjectManager > GetInstance(void)
Return the existing object manager or create one.
CSeq_entry_Handle AddTopLevelSeqEntry(CSeq_entry &top_entry, TPriority pri=kPriority_Default, EExist action=eExist_Default)
Add seq_entry, default priority is higher than for defaults or loaders Add object to the score with p...
void RevokeAllDataLoaders(void)
Revoke all registered data loaders, even if they were still used.
CObjectManager & GetObjectManager(void)
Get object manager controlling this scope.
void Reset(void)
Reset reference object.
IO_PREFIX::ifstream CNcbiIfstream
Portable alias for ifstream.
The blob sat and sat key Both must be positive integers</td > n< td > Non empty string The interpretation of the blob id depends on a processor Cassandra n processor expects the following format
static const char * kProtSeqs
Defines classes: CDirEntry, CFile, CDir, CSymLink, CMemoryFile, CFileUtil, CFileLock,...
Utility stuff for more convenient using of Boost.Test library.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4