28 a(1) = 1; a(2) = 2; a(3) = 1;
29 a_sample_cv.ValueSet(a);
30 a_sample_int.ValueSet(2);
31 a_sample_double.ValueSet(3.1);
33 b_sample_cv = a_sample_cv;
47 CPPUNIT_ASSERT_EQUAL( a, a_sample_cv.ValueGet());
48 CPPUNIT_ASSERT_EQUAL( 2.0 , (a_sample_cv.ValueGet())(2));
50 CPPUNIT_ASSERT_EQUAL( a_sample_cv.ValueGet(), b_sample_cv.ValueGet());
52 CPPUNIT_ASSERT_EQUAL( 2, a_sample_int.ValueGet());
53 CPPUNIT_ASSERT_EQUAL( 3.1, a_sample_double.ValueGet());
59 CPPUNIT_ASSERT_EQUAL((
unsigned int) 3,a_sample_cv.DimensionGet());
60 CPPUNIT_ASSERT_EQUAL((
unsigned int) 3,b_sample_cv.DimensionGet());
61 CPPUNIT_ASSERT_EQUAL((
unsigned int) 1,a_sample_int.DimensionGet());
62 CPPUNIT_ASSERT_EQUAL((
unsigned int) 1,a_sample_double.DimensionGet());
69 a_weighted_sample_cv.ValueSet(a);
70 a_weighted_sample_cv.WeightSet(weight);
71 CPPUNIT_ASSERT_EQUAL( weight, a_weighted_sample_cv.WeightGet());
73 b_weighted_sample_cv = a_weighted_sample_cv;
74 CPPUNIT_ASSERT_EQUAL( a_weighted_sample_cv.ValueGet(), b_weighted_sample_cv.ValueGet());
75 CPPUNIT_ASSERT_EQUAL( a_weighted_sample_cv.WeightGet(), b_weighted_sample_cv.WeightGet());
void testSampleDimension()
void testWeightedSample()
CPPUNIT_TEST_SUITE_REGISTRATION(SampleTest)