~ubuntu-branches/ubuntu/wily/openms/wily

« back to all changes in this revision

Viewing changes to source/TEST/ICPLLabeler_test.C

  • Committer: Package Import Robot
  • Author(s): Filippo Rusconi
  • Date: 2013-12-20 11:30:16 UTC
  • mfrom: (5.1.2 sid)
  • Revision ID: package-import@ubuntu.com-20131220113016-wre5g9bteeheq6he
Tags: 1.11.1-3
* remove version number from libbost development package names;
* ensure that AUTHORS is correctly shipped in all packages.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
// -*- mode: C++; tab-width: 2; -*-
2
 
// vi: set ts=2:
3
 
//
4
 
// --------------------------------------------------------------------------
5
 
//                   OpenMS Mass Spectrometry Framework
6
 
// --------------------------------------------------------------------------
7
 
//  Copyright (C) 2003-2011 -- Oliver Kohlbacher, Knut Reinert
8
 
//
9
 
//  This library is free software; you can redistribute it and/or
10
 
//  modify it under the terms of the GNU Lesser General Public
11
 
//  License as published by the Free Software Foundation; either
12
 
//  version 2.1 of the License, or (at your option) any later version.
13
 
//
14
 
//  This library is distributed in the hope that it will be useful,
15
 
//  but WITHOUT ANY WARRANTY; without even the implied warranty of
16
 
//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
17
 
//  Lesser General Public License for more details.
18
 
//
19
 
//  You should have received a copy of the GNU Lesser General Public
20
 
//  License along with this library; if not, write to the Free Software
21
 
//  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
22
 
//
 
1
// --------------------------------------------------------------------------
 
2
//                   OpenMS -- Open-Source Mass Spectrometry               
 
3
// --------------------------------------------------------------------------
 
4
// Copyright The OpenMS Team -- Eberhard Karls University Tuebingen,
 
5
// ETH Zurich, and Freie Universitaet Berlin 2002-2013.
 
6
// 
 
7
// This software is released under a three-clause BSD license:
 
8
//  * Redistributions of source code must retain the above copyright
 
9
//    notice, this list of conditions and the following disclaimer.
 
10
//  * Redistributions in binary form must reproduce the above copyright
 
11
//    notice, this list of conditions and the following disclaimer in the
 
12
//    documentation and/or other materials provided with the distribution.
 
13
//  * Neither the name of any author or any participating institution 
 
14
//    may be used to endorse or promote products derived from this software 
 
15
//    without specific prior written permission.
 
16
// For a full list of authors, refer to the file AUTHORS. 
 
17
// --------------------------------------------------------------------------
 
18
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
 
19
// AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 
20
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 
21
// ARE DISCLAIMED. IN NO EVENT SHALL ANY OF THE AUTHORS OR THE CONTRIBUTING 
 
22
// INSTITUTIONS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 
 
23
// EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 
 
24
// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 
 
25
// OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 
 
26
// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR 
 
27
// OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 
 
28
// ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
29
// 
23
30
// --------------------------------------------------------------------------
24
31
// $Maintainer: Stephan Aiche$
25
32
// $Authors: Stephan Aiche, Frederic Lehnert, Fabian Kriegel $
36
43
 
37
44
void createTestFeatureMapSimVector_(FeatureMapSimVector& feature_maps, bool add3rd)
38
45
{
39
 
        feature_maps.clear();
40
 
 
41
 
        FeatureMapSim fm1,fm2,fm3;
42
 
        ProteinHit prothit1,prothit2,prothit3,prothit4,prothit5,prothit6,prothit7,prothit8,prothit9,prothit10, prothit11, prothit12;
43
 
 
44
 
        // create first map
45
 
        prothit1.setSequence("AAAAAAAKAAAAA"); // 2 Fragmente AAAAAAAK und AAAAA und kommt in allen Channels vor
46
 
        prothit1.setMetaValue("description", "test sequence 1");
47
 
        prothit1.setAccession("ACC1");
48
 
        prothit1.setMetaValue("intensity", 200.0);
49
 
 
50
 
        prothit2.setSequence("CNARCNCNCN"); // 2 Fragmente CNAR und CNCNCN und kommt in allen Channels vor
51
 
        prothit2.setMetaValue("description", "test sequence 2");
52
 
        prothit2.setAccession("ACC2");
53
 
        prothit2.setMetaValue("intensity", 80.0);
54
 
 
55
 
        prothit3.setSequence("CNHAADDAAAAA"); // ungelabelt, einzelnes Fragment
56
 
        prothit3.setMetaValue("description", "test sequence 3");
57
 
        prothit3.setAccession("ACC3");
58
 
        prothit3.setMetaValue("intensity", 100.0);
59
 
 
60
 
        prothit4.setSequence("VNAAAAAARVNCNCNAAAA"); // Ergebnis: CNAAAAAAR(Label Medium_R) , CNCNCNAAAA (einmal kommt in allen Channels vor)
61
 
        prothit4.setMetaValue("description", "test sequence 4");
62
 
        prothit4.setAccession("ACC5");
63
 
        prothit4.setMetaValue("intensity", 115.0);
64
 
 
65
 
        ProteinIdentification protIdent1;
66
 
        protIdent1.insertHit(prothit1);
67
 
        protIdent1.insertHit(prothit2);
68
 
        protIdent1.insertHit(prothit3);
69
 
        protIdent1.insertHit(prothit4);
70
 
        vector<ProteinIdentification> protIdents_vec1;
71
 
        protIdents_vec1.push_back(protIdent1);
72
 
        fm1.setProteinIdentifications(protIdents_vec1);
73
 
 
74
 
        // create second map
75
 
        prothit5.setSequence("AAAAAAAKAAAAA"); // Ergbenis: AAAAAAAK(Label Medium_K) , AAAAA ( einmal kommt in allen Channels vor)
76
 
        prothit5.setMetaValue("description", "test sequence 5");
77
 
        prothit5.setAccession("ACC4");
78
 
        prothit5.setMetaValue("intensity", 50.0);
79
 
 
80
 
        prothit6.setSequence("CNARCNCNCN"); // Ergebnis: CNAR(Label Medium_R) , CNCNCN (einmal kommt in allen Channels vor)
81
 
        prothit6.setMetaValue("description", "test sequence 6");
82
 
        prothit6.setAccession("ACC5");
83
 
        prothit6.setMetaValue("intensity", 100.0);
84
 
 
85
 
        prothit7.setSequence("LDRCEL"); // Ergbenis : LDR(label Medium_R) , CEL (einmal kommt in channel 2 und 3 vor)
86
 
        prothit7.setMetaValue("description", "test sequence 7");
87
 
        prothit7.setAccession("ACC6");
88
 
        prothit7.setMetaValue("intensity", 120.0);
89
 
 
90
 
        prothit8.setSequence("VNAAAAAARVNCNCNAAAA"); // Ergebnis: CNAAAAAAR(Label Medium_R) , CNCNCNAAAA (einmal kommt in allen Channels vor)
91
 
        prothit8.setMetaValue("description", "test sequence 8");
92
 
        prothit8.setAccession("ACC5");
93
 
        prothit8.setMetaValue("intensity", 110.0);
94
 
 
95
 
        ProteinIdentification protIdent2;
96
 
        protIdent2.insertHit(prothit5);
97
 
        protIdent2.insertHit(prothit6);
98
 
        protIdent2.insertHit(prothit7);
99
 
        protIdent2.insertHit(prothit8);
100
 
        vector<ProteinIdentification> protIdents_vec2;
101
 
        protIdents_vec2.push_back(protIdent2);
102
 
        fm2.setProteinIdentifications(protIdents_vec2);
103
 
 
104
 
        feature_maps.push_back(fm1);
105
 
        feature_maps.push_back(fm2);
106
 
 
107
 
        if (add3rd)
108
 
        {
109
 
                prothit9.setSequence("AAAAAAAKAAAAA"); // Ergebnis : AAAAAAAK(Label Heavy_K) , AAAAA ( einmal kommt in allen Channels vor )
110
 
                prothit9.setMetaValue("description", "test sequence 9");
111
 
                prothit9.setAccession("ACC7");
112
 
                prothit9.setMetaValue("intensity", 30.0);
113
 
 
114
 
                prothit10.setSequence("CNARCNCNCN"); // Ergebnis: CNAR(Label Heavy_R) , CNCNCN (einmal kommt in allen Channels vor)
115
 
                prothit10.setMetaValue("description", "test sequence 10");
116
 
                prothit10.setAccession("ACC8");
117
 
                prothit10.setMetaValue("intensity", 130.0);
118
 
 
119
 
                prothit11.setSequence("LDRCEL"); //Ergebnis: LDR(label Heavy_R) , CEL (einmal kommt in channel 2 und 3 vor)
120
 
                prothit11.setMetaValue("description", "test sequence 11");
121
 
                prothit11.setAccession("ACC9");
122
 
                prothit11.setMetaValue("intensity", 70.0);
123
 
 
124
 
                prothit12.setSequence("YCYCY"); //Ergebnis: YCYCY kommt nur in diesem Channel vor
125
 
                prothit12.setMetaValue("description", "test sequence 12");
126
 
                prothit12.setAccession("ACC10");
127
 
                prothit12.setMetaValue("intensity", 80.0);
128
 
 
129
 
                ProteinIdentification protIdent3;
130
 
                protIdent3.insertHit(prothit9);
131
 
                protIdent3.insertHit(prothit10);
132
 
                protIdent3.insertHit(prothit11);
133
 
                protIdent3.insertHit(prothit12);
134
 
                vector<ProteinIdentification> protIdents_vec3;
135
 
                protIdents_vec3.push_back(protIdent3);
136
 
                fm3.setProteinIdentifications(protIdents_vec3);
137
 
                feature_maps.push_back(fm3);
138
 
        }
 
46
  feature_maps.clear();
 
47
 
 
48
  FeatureMapSim fm1,fm2,fm3;
 
49
  ProteinHit prothit1,prothit2,prothit3,prothit4,prothit5,prothit6,prothit7,prothit8,prothit9,prothit10, prothit11, prothit12;
 
50
 
 
51
  // create first map
 
52
  prothit1.setSequence("AAAAAAAKAAAAA"); // 2 Fragmente AAAAAAAK und AAAAA und kommt in allen Channels vor
 
53
  prothit1.setMetaValue("description", "test sequence 1");
 
54
  prothit1.setAccession("ACC1");
 
55
  prothit1.setMetaValue("intensity", 200.0);
 
56
 
 
57
  prothit2.setSequence("CNARCNCNCN"); // 2 Fragmente CNAR und CNCNCN und kommt in allen Channels vor
 
58
  prothit2.setMetaValue("description", "test sequence 2");
 
59
  prothit2.setAccession("ACC2");
 
60
  prothit2.setMetaValue("intensity", 80.0);
 
61
 
 
62
  prothit3.setSequence("CNHAADDAAAAA"); // ungelabelt, einzelnes Fragment
 
63
  prothit3.setMetaValue("description", "test sequence 3");
 
64
  prothit3.setAccession("ACC3");
 
65
  prothit3.setMetaValue("intensity", 100.0);
 
66
 
 
67
  prothit4.setSequence("VNAAAAAARVNCNCNAAAA"); // Ergebnis: CNAAAAAAR(Label Medium_R) , CNCNCNAAAA (einmal kommt in allen Channels vor)
 
68
  prothit4.setMetaValue("description", "test sequence 4");
 
69
  prothit4.setAccession("ACC5");
 
70
  prothit4.setMetaValue("intensity", 115.0);
 
71
 
 
72
  ProteinIdentification protIdent1;
 
73
  protIdent1.insertHit(prothit1);
 
74
  protIdent1.insertHit(prothit2);
 
75
  protIdent1.insertHit(prothit3);
 
76
  protIdent1.insertHit(prothit4);
 
77
  vector<ProteinIdentification> protIdents_vec1;
 
78
  protIdents_vec1.push_back(protIdent1);
 
79
  fm1.setProteinIdentifications(protIdents_vec1);
 
80
 
 
81
  // create second map
 
82
  prothit5.setSequence("AAAAAAAKAAAAA"); // Ergbenis: AAAAAAAK(Label Medium_K) , AAAAA ( einmal kommt in allen Channels vor)
 
83
  prothit5.setMetaValue("description", "test sequence 5");
 
84
  prothit5.setAccession("ACC4");
 
85
  prothit5.setMetaValue("intensity", 50.0);
 
86
 
 
87
  prothit6.setSequence("CNARCNCNCN"); // Ergebnis: CNAR(Label Medium_R) , CNCNCN (einmal kommt in allen Channels vor)
 
88
  prothit6.setMetaValue("description", "test sequence 6");
 
89
  prothit6.setAccession("ACC5");
 
90
  prothit6.setMetaValue("intensity", 100.0);
 
91
 
 
92
  prothit7.setSequence("LDRCEL"); // Ergbenis : LDR(label Medium_R) , CEL (einmal kommt in channel 2 und 3 vor)
 
93
  prothit7.setMetaValue("description", "test sequence 7");
 
94
  prothit7.setAccession("ACC6");
 
95
  prothit7.setMetaValue("intensity", 120.0);
 
96
 
 
97
  prothit8.setSequence("VNAAAAAARVNCNCNAAAA"); // Ergebnis: CNAAAAAAR(Label Medium_R) , CNCNCNAAAA (einmal kommt in allen Channels vor)
 
98
  prothit8.setMetaValue("description", "test sequence 8");
 
99
  prothit8.setAccession("ACC5");
 
100
  prothit8.setMetaValue("intensity", 110.0);
 
101
 
 
102
  ProteinIdentification protIdent2;
 
103
  protIdent2.insertHit(prothit5);
 
104
  protIdent2.insertHit(prothit6);
 
105
  protIdent2.insertHit(prothit7);
 
106
  protIdent2.insertHit(prothit8);
 
107
  vector<ProteinIdentification> protIdents_vec2;
 
108
  protIdents_vec2.push_back(protIdent2);
 
109
  fm2.setProteinIdentifications(protIdents_vec2);
 
110
 
 
111
  feature_maps.push_back(fm1);
 
112
  feature_maps.push_back(fm2);
 
113
 
 
114
  if (add3rd)
 
115
  {
 
116
    prothit9.setSequence("AAAAAAAKAAAAA"); // Ergebnis : AAAAAAAK(Label Heavy_K) , AAAAA ( einmal kommt in allen Channels vor )
 
117
    prothit9.setMetaValue("description", "test sequence 9");
 
118
    prothit9.setAccession("ACC7");
 
119
    prothit9.setMetaValue("intensity", 30.0);
 
120
 
 
121
    prothit10.setSequence("CNARCNCNCN"); // Ergebnis: CNAR(Label Heavy_R) , CNCNCN (einmal kommt in allen Channels vor)
 
122
    prothit10.setMetaValue("description", "test sequence 10");
 
123
    prothit10.setAccession("ACC8");
 
124
    prothit10.setMetaValue("intensity", 130.0);
 
125
 
 
126
    prothit11.setSequence("LDRCEL"); //Ergebnis: LDR(label Heavy_R) , CEL (einmal kommt in channel 2 und 3 vor)
 
127
    prothit11.setMetaValue("description", "test sequence 11");
 
128
    prothit11.setAccession("ACC9");
 
129
    prothit11.setMetaValue("intensity", 70.0);
 
130
 
 
131
    prothit12.setSequence("YCYCY"); //Ergebnis: YCYCY kommt nur in diesem Channel vor
 
132
    prothit12.setMetaValue("description", "test sequence 12");
 
133
    prothit12.setAccession("ACC10");
 
134
    prothit12.setMetaValue("intensity", 80.0);
 
135
 
 
136
    ProteinIdentification protIdent3;
 
137
    protIdent3.insertHit(prothit9);
 
138
    protIdent3.insertHit(prothit10);
 
139
    protIdent3.insertHit(prothit11);
 
140
    protIdent3.insertHit(prothit12);
 
141
    vector<ProteinIdentification> protIdents_vec3;
 
142
    protIdents_vec3.push_back(protIdent3);
 
143
    fm3.setProteinIdentifications(protIdents_vec3);
 
144
    feature_maps.push_back(fm3);
 
145
  }
139
146
}
140
147
 
141
148
 
142
149
void digestFeaturesMapSimVector_(FeatureMapSimVector& feature_maps)
143
150
{
144
 
        // digest here
145
 
        DigestSimulation digest_sim;
146
 
        Param p;
147
 
        p.setValue("model", "naive");
148
 
        p.setValue("model_naive:missed_cleavages", 0);
149
 
        digest_sim.setParameters(p);
150
 
        std::cout << digest_sim.getParameters() << std::endl;
151
 
        for(FeatureMapSimVector::iterator iter = feature_maps.begin() ; iter != feature_maps.end() ; ++iter)
152
 
        {
153
 
                digest_sim.digest((*iter));
154
 
        }
 
151
  // digest here
 
152
  DigestSimulation digest_sim;
 
153
  Param p;
 
154
  p.setValue("model", "naive");
 
155
  p.setValue("model_naive:missed_cleavages", 0);
 
156
  digest_sim.setParameters(p);
 
157
  std::cout << digest_sim.getParameters() << std::endl;
 
158
  for(FeatureMapSimVector::iterator iter = feature_maps.begin() ; iter != feature_maps.end() ; ++iter)
 
159
  {
 
160
    digest_sim.digest((*iter));
 
161
  }
155
162
}
156
163
 
157
 
START_TEST(ICPLLabeler, "$Id: ICPLLabeler_test.C 8944 2011-10-08 21:50:52Z aiche $")
 
164
START_TEST(ICPLLabeler, "$Id: ICPLLabeler_test.C 10915 2013-04-04 20:14:57Z aiche $")
158
165
/////////////////////////////////////////////////////////////
159
166
/////////////////////////////////////////////////////////////
160
167
 
161
168
ICPLLabeler* ptr = 0;
 
169
ICPLLabeler* nullPtr = 0;
 
170
 
162
171
START_SECTION(ICPLLabeler())
163
172
{
164
 
        ptr = new ICPLLabeler();
165
 
        TEST_NOT_EQUAL(ptr, 0)
 
173
  ptr = new ICPLLabeler();
 
174
  TEST_NOT_EQUAL(ptr, nullPtr)
166
175
}
167
176
END_SECTION
168
177
 
169
178
START_SECTION(~ICPLLabeler())
170
179
{
171
 
        delete ptr;
 
180
  delete ptr;
172
181
}
173
182
END_SECTION
174
183
 
175
184
START_SECTION((void setUpHook(FeatureMapSimVector &)))
176
185
{
177
 
        std::cerr << "*********************************setUpHook*************************************" ;
178
 
        ICPLLabeler labeler;
179
 
 
180
 
        FeatureMapSim fm1,fm2,fm3,fm4;
181
 
        FeatureMapSimVector fm_vec;
182
 
 
183
 
        fm_vec.push_back(fm1);
184
 
        TEST_EXCEPTION_WITH_MESSAGE(Exception::IllegalArgument, labeler.setUpHook(fm_vec),"We currently support only 2- or 3-channel ICPL")
185
 
        fm_vec.push_back(fm2);
186
 
        labeler.setUpHook(fm_vec);
187
 
        fm_vec.push_back(fm3);
188
 
        labeler.setUpHook(fm_vec);
189
 
        fm_vec.push_back(fm4);
190
 
        TEST_EXCEPTION_WITH_MESSAGE(Exception::IllegalArgument, labeler.setUpHook(fm_vec),"We currently support only 2- or 3-channel ICPL")
 
186
  std::cerr << "*********************************setUpHook*************************************" ;
 
187
  ICPLLabeler labeler;
 
188
 
 
189
  FeatureMapSim fm1,fm2,fm3,fm4;
 
190
  FeatureMapSimVector fm_vec;
 
191
 
 
192
  fm_vec.push_back(fm1);
 
193
  TEST_EXCEPTION_WITH_MESSAGE(Exception::IllegalArgument, labeler.setUpHook(fm_vec),"We currently support only 2- or 3-channel ICPL")
 
194
  fm_vec.push_back(fm2);
 
195
  labeler.setUpHook(fm_vec);
 
196
  fm_vec.push_back(fm3);
 
197
  labeler.setUpHook(fm_vec);
 
198
  fm_vec.push_back(fm4);
 
199
  TEST_EXCEPTION_WITH_MESSAGE(Exception::IllegalArgument, labeler.setUpHook(fm_vec),"We currently support only 2- or 3-channel ICPL")
191
200
}
192
201
END_SECTION
193
202
 
194
203
START_SECTION((void postDigestHook(FeatureMapSimVector &)))
195
204
{
196
 
        std::cerr <<"*********************************postDigestHook****************************************";
197
 
        FeatureMapSimVector feature_maps;
 
205
  std::cerr <<"*********************************postDigestHook****************************************";
 
206
  FeatureMapSimVector feature_maps;
198
207
 
199
208
 
200
209
//*******************************Peptide-Labeling*******************************************
201
 
        Param p1;
202
 
  p1.setValue("label_proteins","true");         //set to true for protein_labeling
203
 
 
204
 
 
205
 
        //************2 Channel Protein Labeler********************
206
 
        createTestFeatureMapSimVector_(feature_maps, false);
207
 
 
208
 
        ICPLLabeler protein_labeler;
209
 
        protein_labeler.setParameters(p1);
210
 
 
211
 
        protein_labeler.setUpHook(feature_maps);                // Labeling
212
 
        digestFeaturesMapSimVector_(feature_maps);              // Digest
213
 
        // maps are digested by now
214
 
        protein_labeler.postDigestHook(feature_maps);   // Merge
215
 
 
216
 
        //�berpr�ft, ob das Ergebnis des Labelings und des Verdaus das erwartete Ergebnis ist.
217
 
        TEST_EQUAL(feature_maps.size(), 1)
218
 
        ABORT_IF(feature_maps.size() != 1)
219
 
 
220
 
        TEST_EQUAL(feature_maps[0].size(), 12)
221
 
        ABORT_IF(feature_maps[0].size() != 12)
222
 
 
223
 
        TEST_EQUAL(feature_maps[0][0].getIntensity(), 50)
224
 
        TEST_EQUAL(feature_maps[0][0].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))AAAAAAAK")
225
 
 
226
 
        TEST_EQUAL(feature_maps[0][1].getIntensity(), 100)
227
 
        TEST_EQUAL(feature_maps[0][1].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))CNAR")
228
 
 
229
 
        TEST_EQUAL(feature_maps[0][2].getIntensity(), 120)
230
 
        TEST_EQUAL(feature_maps[0][2].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))LDR")
231
 
 
232
 
        TEST_EQUAL(feature_maps[0][3].getIntensity(), 110)
233
 
        TEST_EQUAL(feature_maps[0][3].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))VNAAAAAAR")
234
 
 
235
 
        TEST_EQUAL(feature_maps[0][4].getIntensity(), 250)
236
 
        TEST_EQUAL(feature_maps[0][4].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "AAAAA")
237
 
 
238
 
        TEST_EQUAL(feature_maps[0][5].getIntensity(), 120)
239
 
        TEST_EQUAL(feature_maps[0][5].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "CEL")
240
 
 
241
 
        TEST_EQUAL(feature_maps[0][6].getIntensity(), 180)
242
 
        TEST_EQUAL(feature_maps[0][6].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "CNCNCN")
243
 
 
244
 
        TEST_EQUAL(feature_maps[0][7].getIntensity(), 225)
245
 
        TEST_EQUAL(feature_maps[0][7].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "VNCNCNAAAA")
246
 
 
247
 
        TEST_EQUAL(feature_maps[0][8].getIntensity(), 200)
248
 
        TEST_EQUAL(feature_maps[0][8].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)AAAAAAAK")
249
 
 
250
 
        TEST_EQUAL(feature_maps[0][9].getIntensity(), 80)
251
 
        TEST_EQUAL(feature_maps[0][9].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNAR")
252
 
 
253
 
        TEST_EQUAL(feature_maps[0][10].getIntensity(), 100)
254
 
        TEST_EQUAL(feature_maps[0][10].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNHAADDAAAAA")
255
 
 
256
 
        TEST_EQUAL(feature_maps[0][11].getIntensity(), 115)
257
 
        TEST_EQUAL(feature_maps[0][11].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)VNAAAAAAR")
258
 
 
259
 
        
260
 
        //************3 Channel Protein Labeler********************
261
 
        createTestFeatureMapSimVector_(feature_maps, true);
262
 
 
263
 
        ICPLLabeler three_channel_protein_labeler;
264
 
        three_channel_protein_labeler.setParameters(p1);
265
 
 
266
 
        three_channel_protein_labeler.setUpHook(feature_maps);          //.Labeling
267
 
        digestFeaturesMapSimVector_(feature_maps);                                      //.Digest
268
 
        // maps are digested by now
269
 
        three_channel_protein_labeler.postDigestHook(feature_maps);     //.Merge
270
 
 
271
 
        //�berpr�ft, ob das Ergebnis des Labelings und des Verdaus das erwartete Ergebnis ist.
272
 
        TEST_EQUAL(feature_maps.size(), 1)
273
 
        ABORT_IF(feature_maps.size() != 1)
274
 
 
275
 
        TEST_EQUAL(feature_maps[0].size(), 16)
276
 
        ABORT_IF(feature_maps[0].size() != 16)
277
 
 
278
 
        TEST_EQUAL(feature_maps[0][0].getIntensity(), 30)
279
 
        TEST_EQUAL(feature_maps[0][0].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:13C(6))AAAAAAAK")
 
210
  Param p1;
 
211
  p1.setValue("label_proteins","true");    //set to true for protein_labeling
 
212
 
 
213
 
 
214
  //************2 Channel Protein Labeler********************
 
215
  createTestFeatureMapSimVector_(feature_maps, false);
 
216
 
 
217
  ICPLLabeler protein_labeler;
 
218
  protein_labeler.setParameters(p1);
 
219
 
 
220
  protein_labeler.setUpHook(feature_maps);    // Labeling
 
221
  digestFeaturesMapSimVector_(feature_maps);    // Digest
 
222
  // maps are digested by now
 
223
  protein_labeler.postDigestHook(feature_maps);  // Merge
 
224
 
 
225
  TEST_EQUAL(feature_maps.size(), 1)
 
226
  ABORT_IF(feature_maps.size() != 1)
 
227
 
 
228
  TEST_EQUAL(feature_maps[0].size(), 12)
 
229
  ABORT_IF(feature_maps[0].size() != 12)
 
230
 
 
231
  TEST_EQUAL(feature_maps[0][0].getIntensity(), 50)
 
232
  TEST_EQUAL(feature_maps[0][0].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))AAAAAAAK")
 
233
 
 
234
  TEST_EQUAL(feature_maps[0][1].getIntensity(), 100)
 
235
  TEST_EQUAL(feature_maps[0][1].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))CNAR")
 
236
 
 
237
  TEST_EQUAL(feature_maps[0][2].getIntensity(), 120)
 
238
  TEST_EQUAL(feature_maps[0][2].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))LDR")
 
239
 
 
240
  TEST_EQUAL(feature_maps[0][3].getIntensity(), 110)
 
241
  TEST_EQUAL(feature_maps[0][3].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))VNAAAAAAR")
 
242
 
 
243
  TEST_EQUAL(feature_maps[0][4].getIntensity(), 250)
 
244
  TEST_EQUAL(feature_maps[0][4].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "AAAAA")
 
245
 
 
246
  TEST_EQUAL(feature_maps[0][5].getIntensity(), 120)
 
247
  TEST_EQUAL(feature_maps[0][5].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "CEL")
 
248
 
 
249
  TEST_EQUAL(feature_maps[0][6].getIntensity(), 180)
 
250
  TEST_EQUAL(feature_maps[0][6].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "CNCNCN")
 
251
 
 
252
  TEST_EQUAL(feature_maps[0][7].getIntensity(), 225)
 
253
  TEST_EQUAL(feature_maps[0][7].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "VNCNCNAAAA")
 
254
 
 
255
  TEST_EQUAL(feature_maps[0][8].getIntensity(), 200)
 
256
  TEST_EQUAL(feature_maps[0][8].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)AAAAAAAK")
 
257
 
 
258
  TEST_EQUAL(feature_maps[0][9].getIntensity(), 80)
 
259
  TEST_EQUAL(feature_maps[0][9].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNAR")
 
260
 
 
261
  TEST_EQUAL(feature_maps[0][10].getIntensity(), 100)
 
262
  TEST_EQUAL(feature_maps[0][10].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNHAADDAAAAA")
 
263
 
 
264
  TEST_EQUAL(feature_maps[0][11].getIntensity(), 115)
 
265
  TEST_EQUAL(feature_maps[0][11].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)VNAAAAAAR")
 
266
 
 
267
  
 
268
  //************3 Channel Protein Labeler********************
 
269
  createTestFeatureMapSimVector_(feature_maps, true);
 
270
 
 
271
  ICPLLabeler three_channel_protein_labeler;
 
272
  three_channel_protein_labeler.setParameters(p1);
 
273
 
 
274
  three_channel_protein_labeler.setUpHook(feature_maps);    //.Labeling
 
275
  digestFeaturesMapSimVector_(feature_maps);          //.Digest
 
276
  // maps are digested by now
 
277
  three_channel_protein_labeler.postDigestHook(feature_maps);  //.Merge
 
278
 
 
279
  TEST_EQUAL(feature_maps.size(), 1)
 
280
  ABORT_IF(feature_maps.size() != 1)
 
281
 
 
282
  TEST_EQUAL(feature_maps[0].size(), 16)
 
283
  ABORT_IF(feature_maps[0].size() != 16)
 
284
 
 
285
  TEST_EQUAL(feature_maps[0][0].getIntensity(), 30)
 
286
  TEST_EQUAL(feature_maps[0][0].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:13C(6))AAAAAAAK")
280
287
 
281
288
  TEST_EQUAL(feature_maps[0][7].getIntensity(), 50)
282
289
  TEST_EQUAL(feature_maps[0][7].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))AAAAAAAK")
305
312
  TEST_EQUAL(feature_maps[0][3].getIntensity(), 80)
306
313
  TEST_EQUAL(feature_maps[0][3].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:13C(6))YCYCY")
307
314
 
308
 
        TEST_EQUAL(feature_maps[0][10].getIntensity(), 110)
309
 
        TEST_EQUAL(feature_maps[0][10].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))VNAAAAAAR")
310
 
 
311
 
        TEST_EQUAL(feature_maps[0][11].getIntensity(), 225)
312
 
        TEST_EQUAL(feature_maps[0][11].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "VNCNCNAAAA")
313
 
 
314
 
        TEST_EQUAL(feature_maps[0][12].getIntensity(), 200)
315
 
        TEST_EQUAL(feature_maps[0][12].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)AAAAAAAK")
316
 
 
317
 
        TEST_EQUAL(feature_maps[0][13].getIntensity(), 80)
318
 
        TEST_EQUAL(feature_maps[0][13].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNAR")
319
 
 
320
 
        TEST_EQUAL(feature_maps[0][14].getIntensity(), 100)
321
 
        TEST_EQUAL(feature_maps[0][14].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNHAADDAAAAA")
322
 
 
323
 
        TEST_EQUAL(feature_maps[0][15].getIntensity(), 115)
324
 
        TEST_EQUAL(feature_maps[0][15].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)VNAAAAAAR")
 
315
  TEST_EQUAL(feature_maps[0][10].getIntensity(), 110)
 
316
  TEST_EQUAL(feature_maps[0][10].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))VNAAAAAAR")
 
317
 
 
318
  TEST_EQUAL(feature_maps[0][11].getIntensity(), 225)
 
319
  TEST_EQUAL(feature_maps[0][11].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "VNCNCNAAAA")
 
320
 
 
321
  TEST_EQUAL(feature_maps[0][12].getIntensity(), 200)
 
322
  TEST_EQUAL(feature_maps[0][12].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)AAAAAAAK")
 
323
 
 
324
  TEST_EQUAL(feature_maps[0][13].getIntensity(), 80)
 
325
  TEST_EQUAL(feature_maps[0][13].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNAR")
 
326
 
 
327
  TEST_EQUAL(feature_maps[0][14].getIntensity(), 100)
 
328
  TEST_EQUAL(feature_maps[0][14].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNHAADDAAAAA")
 
329
 
 
330
  TEST_EQUAL(feature_maps[0][15].getIntensity(), 115)
 
331
  TEST_EQUAL(feature_maps[0][15].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)VNAAAAAAR")
325
332
 
326
333
 
327
334
//*******************************Peptide-Labeling*******************************************
328
335
 
329
 
        Param p2;
330
 
  p2.setValue("label_proteins","false");                //set to false for peptide_labeling
331
 
 
332
 
 
333
 
        //************2 Channel Peptide Labeler
334
 
        createTestFeatureMapSimVector_(feature_maps, false);
335
 
 
336
 
        ICPLLabeler peptide_labeler;
337
 
        peptide_labeler.setParameters(p2);
 
336
  Param p2;
 
337
  p2.setValue("label_proteins","false");    //set to false for peptide_labeling
 
338
 
 
339
 
 
340
  //************2 Channel Peptide Labeler
 
341
  createTestFeatureMapSimVector_(feature_maps, false);
 
342
 
 
343
  ICPLLabeler peptide_labeler;
 
344
  peptide_labeler.setParameters(p2);
338
345
  peptide_labeler.setUpHook(feature_maps);
339
 
        digestFeaturesMapSimVector_(feature_maps);                                              // Digest
340
 
        peptide_labeler.postDigestHook(feature_maps);                                   // Labeling & Merge
341
 
 
342
 
        //�berpr�ft, ob das Ergebnis des Labelings und des Verdaus das erwartete Ergebnis ist.
343
 
        TEST_EQUAL(feature_maps.size(), 1)
344
 
        ABORT_IF(feature_maps.size() != 1)
345
 
 
346
 
        TEST_EQUAL(feature_maps[0].size(), 15)
347
 
        ABORT_IF(feature_maps[0].size() != 15)
348
 
 
349
 
        TEST_EQUAL(feature_maps[0][0].getIntensity(), 50)
350
 
        TEST_EQUAL(feature_maps[0][0].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))AAAAA")
 
346
  digestFeaturesMapSimVector_(feature_maps);            // Digest
 
347
  peptide_labeler.postDigestHook(feature_maps);          // Labeling & Merge
 
348
 
 
349
  TEST_EQUAL(feature_maps.size(), 1)
 
350
  ABORT_IF(feature_maps.size() != 1)
 
351
 
 
352
  TEST_EQUAL(feature_maps[0].size(), 15)
 
353
  ABORT_IF(feature_maps[0].size() != 15)
 
354
 
 
355
  TEST_EQUAL(feature_maps[0][0].getIntensity(), 50)
 
356
  TEST_EQUAL(feature_maps[0][0].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))AAAAA")
351
357
 
352
358
  TEST_EQUAL(feature_maps[0][1].getIntensity(), 50)
353
359
  TEST_EQUAL(feature_maps[0][1].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))AAAAAAAK")
355
361
  TEST_EQUAL(feature_maps[0][2].getIntensity(), 120)
356
362
  TEST_EQUAL(feature_maps[0][2].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))CEL")
357
363
 
358
 
        TEST_EQUAL(feature_maps[0][3].getIntensity(), 100)
359
 
        TEST_EQUAL(feature_maps[0][3].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))CNAR")
360
 
 
361
 
        TEST_EQUAL(feature_maps[0][4].getIntensity(), 100)
362
 
        TEST_EQUAL(feature_maps[0][4].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))CNCNCN")
363
 
 
364
 
        TEST_EQUAL(feature_maps[0][5].getIntensity(), 120)
365
 
        TEST_EQUAL(feature_maps[0][5].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))LDR")
366
 
 
367
 
        TEST_EQUAL(feature_maps[0][6].getIntensity(), 110)
368
 
        TEST_EQUAL(feature_maps[0][6].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))VNAAAAAAR")
369
 
 
370
 
        TEST_EQUAL(feature_maps[0][7].getIntensity(), 110)
371
 
        TEST_EQUAL(feature_maps[0][7].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))VNCNCNAAAA")
372
 
 
373
 
        TEST_EQUAL(feature_maps[0][8].getIntensity(), 200)
374
 
        TEST_EQUAL(feature_maps[0][8].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)AAAAA")
375
 
 
376
 
        TEST_EQUAL(feature_maps[0][9].getIntensity(), 200)
377
 
        TEST_EQUAL(feature_maps[0][9].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)AAAAAAAK")
378
 
 
379
 
        TEST_EQUAL(feature_maps[0][10].getIntensity(), 80)
380
 
        TEST_EQUAL(feature_maps[0][10].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNAR")
381
 
 
382
 
        TEST_EQUAL(feature_maps[0][11].getIntensity(), 80)
383
 
        TEST_EQUAL(feature_maps[0][11].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNCNCN")
384
 
 
385
 
        TEST_EQUAL(feature_maps[0][12].getIntensity(), 100)
386
 
        TEST_EQUAL(feature_maps[0][12].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNHAADDAAAAA")
387
 
 
388
 
        TEST_EQUAL(feature_maps[0][13].getIntensity(), 115)
389
 
        TEST_EQUAL(feature_maps[0][13].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)VNAAAAAAR")
390
 
 
391
 
        TEST_EQUAL(feature_maps[0][14].getIntensity(), 115)
392
 
        TEST_EQUAL(feature_maps[0][14].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)VNCNCNAAAA")
393
 
 
394
 
 
395
 
        //************3 Channel Peptide Labeler
396
 
        createTestFeatureMapSimVector_(feature_maps, true);
397
 
 
398
 
        ICPLLabeler three_channel_peptide_labeler;
399
 
        three_channel_peptide_labeler.setParameters(p2);
400
 
 
401
 
        digestFeaturesMapSimVector_(feature_maps);                                              // Digest
402
 
        three_channel_peptide_labeler.postDigestHook(feature_maps);             // Labeling & Merge
403
 
 
404
 
        //�berpr�ft, ob das Ergebnis des Labelings und des Verdaus das erwartete Ergebnis ist.
405
 
        TEST_EQUAL(feature_maps.size(), 1)
406
 
        ABORT_IF(feature_maps.size() != 1)
407
 
 
408
 
        TEST_EQUAL(feature_maps[0].size(), 22)
409
 
        ABORT_IF(feature_maps[0].size() != 22)
410
 
 
411
 
        TEST_EQUAL(feature_maps[0][0].getIntensity(), 30)
412
 
        TEST_EQUAL(feature_maps[0][0].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:13C(6))AAAAA")
 
364
  TEST_EQUAL(feature_maps[0][3].getIntensity(), 100)
 
365
  TEST_EQUAL(feature_maps[0][3].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))CNAR")
 
366
 
 
367
  TEST_EQUAL(feature_maps[0][4].getIntensity(), 100)
 
368
  TEST_EQUAL(feature_maps[0][4].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))CNCNCN")
 
369
 
 
370
  TEST_EQUAL(feature_maps[0][5].getIntensity(), 120)
 
371
  TEST_EQUAL(feature_maps[0][5].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))LDR")
 
372
 
 
373
  TEST_EQUAL(feature_maps[0][6].getIntensity(), 110)
 
374
  TEST_EQUAL(feature_maps[0][6].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))VNAAAAAAR")
 
375
 
 
376
  TEST_EQUAL(feature_maps[0][7].getIntensity(), 110)
 
377
  TEST_EQUAL(feature_maps[0][7].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))VNCNCNAAAA")
 
378
 
 
379
  TEST_EQUAL(feature_maps[0][8].getIntensity(), 200)
 
380
  TEST_EQUAL(feature_maps[0][8].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)AAAAA")
 
381
 
 
382
  TEST_EQUAL(feature_maps[0][9].getIntensity(), 200)
 
383
  TEST_EQUAL(feature_maps[0][9].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)AAAAAAAK")
 
384
 
 
385
  TEST_EQUAL(feature_maps[0][10].getIntensity(), 80)
 
386
  TEST_EQUAL(feature_maps[0][10].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNAR")
 
387
 
 
388
  TEST_EQUAL(feature_maps[0][11].getIntensity(), 80)
 
389
  TEST_EQUAL(feature_maps[0][11].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNCNCN")
 
390
 
 
391
  TEST_EQUAL(feature_maps[0][12].getIntensity(), 100)
 
392
  TEST_EQUAL(feature_maps[0][12].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNHAADDAAAAA")
 
393
 
 
394
  TEST_EQUAL(feature_maps[0][13].getIntensity(), 115)
 
395
  TEST_EQUAL(feature_maps[0][13].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)VNAAAAAAR")
 
396
 
 
397
  TEST_EQUAL(feature_maps[0][14].getIntensity(), 115)
 
398
  TEST_EQUAL(feature_maps[0][14].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)VNCNCNAAAA")
 
399
 
 
400
 
 
401
  //************3 Channel Peptide Labeler
 
402
  createTestFeatureMapSimVector_(feature_maps, true);
 
403
 
 
404
  ICPLLabeler three_channel_peptide_labeler;
 
405
  three_channel_peptide_labeler.setParameters(p2);
 
406
 
 
407
  digestFeaturesMapSimVector_(feature_maps);            // Digest
 
408
  three_channel_peptide_labeler.postDigestHook(feature_maps);    // Labeling & Merge
 
409
 
 
410
  TEST_EQUAL(feature_maps.size(), 1)
 
411
  ABORT_IF(feature_maps.size() != 1)
 
412
 
 
413
  TEST_EQUAL(feature_maps[0].size(), 22)
 
414
  ABORT_IF(feature_maps[0].size() != 22)
 
415
 
 
416
  TEST_EQUAL(feature_maps[0][0].getIntensity(), 30)
 
417
  TEST_EQUAL(feature_maps[0][0].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:13C(6))AAAAA")
413
418
 
414
419
  TEST_EQUAL(feature_maps[0][7].getIntensity(), 50)
415
420
  TEST_EQUAL(feature_maps[0][7].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))AAAAA")
447
452
  TEST_EQUAL(feature_maps[0][6].getIntensity(), 80)
448
453
  TEST_EQUAL(feature_maps[0][6].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:13C(6))YCYCY")
449
454
 
450
 
        TEST_EQUAL(feature_maps[0][13].getIntensity(), 110)
451
 
        TEST_EQUAL(feature_maps[0][13].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))VNAAAAAAR")
452
 
 
453
 
        TEST_EQUAL(feature_maps[0][14].getIntensity(), 110)
454
 
        TEST_EQUAL(feature_maps[0][14].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))VNCNCNAAAA")
455
 
 
456
 
        TEST_EQUAL(feature_maps[0][15].getIntensity(), 200)
457
 
        TEST_EQUAL(feature_maps[0][15].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)AAAAA")
458
 
 
459
 
        TEST_EQUAL(feature_maps[0][16].getIntensity(), 200)
460
 
        TEST_EQUAL(feature_maps[0][16].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)AAAAAAAK")
461
 
 
462
 
        TEST_EQUAL(feature_maps[0][17].getIntensity(), 80)
463
 
        TEST_EQUAL(feature_maps[0][17].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNAR")
464
 
 
465
 
        TEST_EQUAL(feature_maps[0][18].getIntensity(), 80)
466
 
        TEST_EQUAL(feature_maps[0][18].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNCNCN")
467
 
 
468
 
        TEST_EQUAL(feature_maps[0][19].getIntensity(), 100)
469
 
        TEST_EQUAL(feature_maps[0][19].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNHAADDAAAAA")
470
 
 
471
 
        TEST_EQUAL(feature_maps[0][20].getIntensity(), 115)
472
 
        TEST_EQUAL(feature_maps[0][20].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)VNAAAAAAR")
473
 
 
474
 
        TEST_EQUAL(feature_maps[0][21].getIntensity(), 115)
475
 
        TEST_EQUAL(feature_maps[0][21].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)VNCNCNAAAA")
 
455
  TEST_EQUAL(feature_maps[0][13].getIntensity(), 110)
 
456
  TEST_EQUAL(feature_maps[0][13].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))VNAAAAAAR")
 
457
 
 
458
  TEST_EQUAL(feature_maps[0][14].getIntensity(), 110)
 
459
  TEST_EQUAL(feature_maps[0][14].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL:2H(4))VNCNCNAAAA")
 
460
 
 
461
  TEST_EQUAL(feature_maps[0][15].getIntensity(), 200)
 
462
  TEST_EQUAL(feature_maps[0][15].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)AAAAA")
 
463
 
 
464
  TEST_EQUAL(feature_maps[0][16].getIntensity(), 200)
 
465
  TEST_EQUAL(feature_maps[0][16].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)AAAAAAAK")
 
466
 
 
467
  TEST_EQUAL(feature_maps[0][17].getIntensity(), 80)
 
468
  TEST_EQUAL(feature_maps[0][17].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNAR")
 
469
 
 
470
  TEST_EQUAL(feature_maps[0][18].getIntensity(), 80)
 
471
  TEST_EQUAL(feature_maps[0][18].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNCNCN")
 
472
 
 
473
  TEST_EQUAL(feature_maps[0][19].getIntensity(), 100)
 
474
  TEST_EQUAL(feature_maps[0][19].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)CNHAADDAAAAA")
 
475
 
 
476
  TEST_EQUAL(feature_maps[0][20].getIntensity(), 115)
 
477
  TEST_EQUAL(feature_maps[0][20].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)VNAAAAAAR")
 
478
 
 
479
  TEST_EQUAL(feature_maps[0][21].getIntensity(), 115)
 
480
  TEST_EQUAL(feature_maps[0][21].getPeptideIdentifications()[0].getHits()[0].getSequence().toString(), "(ICPL)VNCNCNAAAA")
476
481
 
477
482
}
478
483
END_SECTION
479
484
 
480
485
START_SECTION((void postRawMSHook(FeatureMapSimVector &)))
481
486
{
482
 
        // TODO
 
487
  // TODO
483
488
}
484
489
END_SECTION
485
490
 
489
494
 
490
495
START_SECTION((void preCheck(Param &param) const ))
491
496
{
492
 
        Param p;
493
 
        dummyLabeler.preCheck(p);
 
497
  Param p;
 
498
  dummyLabeler.preCheck(p);
494
499
 
495
 
        // preCheck has no content
496
 
        NOT_TESTABLE
 
500
  // preCheck has no content
 
501
  NOT_TESTABLE
497
502
}
498
503
END_SECTION
499
504
 
500
505
 
501
506
START_SECTION((void postRTHook(FeatureMapSimVector &)))
502
507
{
503
 
        // we do not modify the map in this step
504
 
        dummyLabeler.postRTHook(empty);
505
 
        NOT_TESTABLE
 
508
  // we do not modify the map in this step
 
509
  dummyLabeler.postRTHook(empty);
 
510
  NOT_TESTABLE
506
511
}
507
512
END_SECTION
508
513
 
509
514
START_SECTION((void postDetectabilityHook(FeatureMapSimVector &)))
510
515
{
511
 
        // we do not modify the map in this step
512
 
        dummyLabeler.postDetectabilityHook(empty);
513
 
        NOT_TESTABLE
 
516
  // we do not modify the map in this step
 
517
  dummyLabeler.postDetectabilityHook(empty);
 
518
  NOT_TESTABLE
514
519
}
515
520
END_SECTION
516
521
 
517
522
START_SECTION((void postIonizationHook(FeatureMapSimVector &)))
518
523
{
519
 
        // we do not modify the map in this step
520
 
        dummyLabeler.postIonizationHook(empty);
521
 
        NOT_TESTABLE
 
524
  // we do not modify the map in this step
 
525
  dummyLabeler.postIonizationHook(empty);
 
526
  NOT_TESTABLE
522
527
}
523
528
END_SECTION
524
529
 
525
530
MSSimExperiment exp;
526
531
START_SECTION((void postRawTandemMSHook(FeatureMapSimVector &, MSSimExperiment &)))
527
532
{
528
 
        // we do not modify the map in this step
529
 
        dummyLabeler.postRawTandemMSHook(empty,exp);
530
 
        NOT_TESTABLE
 
533
  // we do not modify the map in this step
 
534
  dummyLabeler.postRawTandemMSHook(empty,exp);
 
535
  NOT_TESTABLE
531
536
}
532
537
END_SECTION
533
538
 
534
539
START_SECTION((static BaseLabeler* create()))
535
540
{
536
 
        BaseLabeler* labeler = ICPLLabeler::create();
537
 
        TEST_NOT_EQUAL(labeler, 0)
538
 
        delete labeler;
 
541
  BaseLabeler* labeler = ICPLLabeler::create();
 
542
  BaseLabeler* nullPointer = 0;
 
543
  TEST_NOT_EQUAL(labeler, nullPointer)
 
544
  delete labeler;
539
545
}
540
546
END_SECTION
541
547
 
542
548
START_SECTION((static const String getProductName()))
543
549
{
544
 
        TEST_EQUAL(ICPLLabeler::getProductName(), "ICPL")
 
550
  TEST_EQUAL(ICPLLabeler::getProductName(), "ICPL")
545
551
}
546
552
END_SECTION
547
553