forked from Kitware/kwant
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtest_phase1.cxx
More file actions
46 lines (34 loc) · 1.14 KB
/
test_phase1.cxx
File metadata and controls
46 lines (34 loc) · 1.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/*ckwg +5
* Copyright 2010 by Kitware, Inc. All Rights Reserved. Please refer to
* KITWARE_LICENSE.TXT for licensing information, or contact General Counsel,
* Kitware, Inc., 28 Corporate Drive, Clifton Park, NY 12065.
*/
#include <iostream>
#include <string>
#include <sstream>
#include <testlib/testlib_test.h>
#include <track_oracle/file_formats/track_kw18/track_kw18.h>
#include <track_oracle/file_formats/track_kw18/track_kw18_reader.h>
#include <scoring_framework/score_phase1.h>
using std::istringstream;
using std::string;
using namespace vidtk;
const string track_1 =
"1 4 1 5 5 0 1 5 5 3 3 7 7 16 5 5 0 10\n";
const string track_2 =
"1 4 2 5 6 0 1 5 6 3 4 7 8 16 5 6 0 11\n"
"1 4 3 5 7 0 1 5 7 3 5 7 9 16 5 7 0 12\n"
"1 4 4 5 8 0 0 5 8 3 6 7 10 16 5 8 0 13\n";
int
test_t1_t1()
{
testlib_test_start( "testOneFrameToSelf" );
istringstream iss( track_1 );
track_list_type t;
track_kw18_reader::read( iss, t );
TEST( "track_1 has one track", (t.size() == 1) )
track2track_phase1 p1;
p1.compute( t, t );
TEST( "t2t has one entry", (p1.t2t.size() == 1) );
return testlib_test_summary();
}