From dac9b62907378a563f1363f63d03ee2d90a1ef57 2012-07-24 13:06:08 From: Marek Rosa Date: 2012-07-24 13:06:08 Subject: [PATCH] Enabled more tests in qdatetimeaxis --- diff --git a/src/axis/datetimeaxis/qdatetimeaxis.cpp b/src/axis/datetimeaxis/qdatetimeaxis.cpp index 3232f36..506b5c1 100644 --- a/src/axis/datetimeaxis/qdatetimeaxis.cpp +++ b/src/axis/datetimeaxis/qdatetimeaxis.cpp @@ -32,6 +32,8 @@ QTCOMMERCIALCHART_BEGIN_NAMESPACE \brief The QDateTimeAxis class is used for manipulating chart's axis. \mainclass + Note that any date before 4800 BCE or after about 1.4 million CE may not be accurately stored. + ValuesAxis can be setup to show axis line with tick marks, grid lines and shades. Values of axis are drawn to position of ticks */ diff --git a/tests/auto/qdatetimeaxis/tst_qdatetimeaxis.cpp b/tests/auto/qdatetimeaxis/tst_qdatetimeaxis.cpp index 1dff5b2..b065236 100644 --- a/tests/auto/qdatetimeaxis/tst_qdatetimeaxis.cpp +++ b/tests/auto/qdatetimeaxis/tst_qdatetimeaxis.cpp @@ -40,20 +40,20 @@ private slots: void max_raw(); void max_data(); void max(); - // void max_animation_data(); - // void max_animation(); + void max_animation_data(); + void max_animation(); void min_raw_data(); void min_raw(); void min_data(); void min(); - // void min_animation_data(); - // void min_animation(); + void min_animation_data(); + void min_animation(); void range_raw_data(); void range_raw(); void range_data(); void range(); - // void range_animation_data(); - // void range_animation(); + void range_animation_data(); + void range_animation(); private: QDateTimeAxis *m_dateTimeAxisX; @@ -107,9 +107,6 @@ void tst_QDateTimeAxis::qdatetimeaxis_data() void tst_QDateTimeAxis::qdatetimeaxis() { // qabstractaxis(); - - // QVERIFY(m_datetimeaxis->max().toMSecsSinceEpoch() == 0); - // QVERIFY(m_datetimeaxis->min().toMSecsSinceEpoch() == 0); QCOMPARE(m_dateTimeAxisX->type(), QAbstractAxis::AxisTypeDateTime); m_view->show(); @@ -141,7 +138,6 @@ void tst_QDateTimeAxis::max_raw() m_dateTimeAxisX->setMax(max); - if (valid) { QVERIFY2(m_dateTimeAxisX->max() == max, "Not equal"); QCOMPARE(spy0.count(), 1); @@ -168,16 +164,16 @@ void tst_QDateTimeAxis::max() max_raw(); } -//void tst_QDateTimeAxis::max_animation_data() -//{ -// max_data(); -//} +void tst_QDateTimeAxis::max_animation_data() +{ + max_data(); +} -//void tst_QDateTimeAxis::max_animation() -//{ -// m_chart->setAnimationOptions(QChart::GridAxisAnimations); -// max(); -//} +void tst_QDateTimeAxis::max_animation() +{ + m_chart->setAnimationOptions(QChart::GridAxisAnimations); + max(); +} void tst_QDateTimeAxis::min_raw_data() { @@ -227,16 +223,16 @@ void tst_QDateTimeAxis::min() min_raw(); } -//void tst_QDateTimeAxis::min_animation_data() -//{ -// min_data(); -//} +void tst_QDateTimeAxis::min_animation_data() +{ + min_data(); +} -//void tst_QDateTimeAxis::min_animation() -//{ -// m_chart->setAnimationOptions(QChart::GridAxisAnimations); -// min(); -//} +void tst_QDateTimeAxis::min_animation() +{ + m_chart->setAnimationOptions(QChart::GridAxisAnimations); + min(); +} void tst_QDateTimeAxis::range_raw_data() { @@ -301,16 +297,16 @@ void tst_QDateTimeAxis::range() range_raw(); } -//void tst_QDateTimeAxis::range_animation_data() -//{ -// range_data(); -//} +void tst_QDateTimeAxis::range_animation_data() +{ + range_data(); +} -//void tst_QDateTimeAxis::range_animation() -//{ -// m_chart->setAnimationOptions(QChart::GridAxisAnimations); -// range(); -//} +void tst_QDateTimeAxis::range_animation() +{ + m_chart->setAnimationOptions(QChart::GridAxisAnimations); + range(); +} QTEST_MAIN(tst_QDateTimeAxis) #include "tst_qdatetimeaxis.moc"