MCPcopy Create free account
hub / github.com/OpenMS/OpenMS / START_SECTION

Function START_SECTION

src/tests/class_tests/openms/source/XTandemXMLFile_test.cpp:46–64  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

44XTandemXMLFile xml_file;
45
46START_SECTION(void load(const String& filename, ProteinIdentification& protein_identification, std::vector<PeptideIdentification>& id_data, ModificationDefinitionsSet& mod_def_set))
47{
48 ModificationDefinitionsSet mod_set(ListUtils::create<String>(""), ListUtils::create<String>("Carbamidomethyl (C),Oxidation (M),Carboxymethyl (C)"));
49
50 xml_file.load(OPENMS_GET_TEST_DATA_PATH("XTandemXMLFile_test.xml"), protein_identification, peptide_identifications, mod_set);
51 TEST_EQUAL(peptide_identifications.size(), 303);
52 TEST_EQUAL(protein_identification.getHits().size(), 497);
53 // should have picked up the default N-terminal modifications:
54 TEST_EQUAL(mod_set.getNumberOfVariableModifications(), 6);
55 TEST_EQUAL(mod_set.getNumberOfFixedModifications(), 0);
56
57 mod_set.setModifications("", "Carbamidomethyl (C),Oxidation (M),Carboxymethyl (C)");
58 xml_file.load(OPENMS_GET_TEST_DATA_PATH("XTandemXMLFile_test_2.xml"), protein_identification, peptide_identifications, mod_set);
59 TEST_EQUAL(peptide_identifications.size(), 2);
60 TEST_EQUAL(protein_identification.getHits().size(), 21);
61 // no additional modifications in this case:
62 TEST_EQUAL(mod_set.getNumberOfVariableModifications(), 3);
63 TEST_EQUAL(mod_set.getNumberOfFixedModifications(), 0);
64}
65END_SECTION
66
67/////////////////////////////////////////////////////////////

Callers 1

Calls 6

TEST_EQUALFunction · 0.85
loadMethod · 0.45
sizeMethod · 0.45
setModificationsMethod · 0.45

Tested by

no test coverage detected