Initial commit
This commit is contained in:
commit
b7d90b9afe
16245 files changed
+3396666
No files matched your search
+74
@@ -0,0 +1,74 @@
|
||||
/**
|
||||
* @RDE_HEADER@
|
||||
* Module tests for SVC ReportManagement
|
||||
* $Id$
|
||||
* $HeadURL$
|
||||
* $Author$
|
||||
* Created by Hanna E. Rathje, SLSE, 2015-09-10
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <ReportManagement/rep_dtc.h>
|
||||
#include <ReportManagement/rep_ftc.h>
|
||||
#include <ReportManagement/rep_ftc_types.h>
|
||||
|
||||
#include <DDS/DDSConnector/dds_connector.h>
|
||||
|
||||
#include <ReportManagement/logger.h>
|
||||
#include <ReportManagement/rep_db.h>
|
||||
|
||||
namespace NGLDB
|
||||
{
|
||||
template <typename DB> class DbServiceHandler;
|
||||
}
|
||||
|
||||
namespace ReportManagement
|
||||
{
|
||||
using DbHandler = NGLDB::DbServiceHandler<DatabaseInterface>;
|
||||
class RepTests : public QObject
|
||||
, protected ReportManagement::Interface::Ftc::CreateModifyReportReplyHandler
|
||||
, protected ReportManagement::Interface::Ftc::RemoveReportReplyHandler
|
||||
, protected ReportManagement::Interface::Ftc::GetReportDataReplyHandler
|
||||
, protected ReportManagement::Interface::Ftc::ReportChangeStatusReplyHandler
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
explicit RepTests(QObject *parent = nullptr);
|
||||
~RepTests();
|
||||
|
||||
bool init(int domainId, int exerciseId, int testId, int reportId, int operatorId);
|
||||
bool testsSuccessful() const { return m_bTestsSuccessful; }
|
||||
|
||||
public Q_SLOTS:
|
||||
void startTest();
|
||||
protected:
|
||||
void tryCreate(ReportManagement::ReportType repType, VisualisationType visType = VisualisationType::Table);
|
||||
void tryModify();
|
||||
void tryGetData();
|
||||
void tryDelete();
|
||||
void tryChangeStatus();
|
||||
void onCreateModifyReportReply(const CreateModifyReportReply &replyObject) override final;
|
||||
void onRemoveReportReply(const Core::FunctionReplyObject &replyObject) override final;
|
||||
void onGetReportDataReply(const GetReportDataReply &replyObject) override final;
|
||||
void onReportChangeStatusReply(const Core::FunctionReplyObject &replyObject) override final;
|
||||
void failExit();
|
||||
void addTestDataTreatmentTimeline();
|
||||
|
||||
private:
|
||||
std::shared_ptr<DDSConnector::DdsConnector> m_ddsConnector;
|
||||
std::shared_ptr<ReportManagement::Interface::Dtc> m_dtc;
|
||||
std::shared_ptr<ReportManagement::Interface::Ftc> m_ftc;
|
||||
std::shared_ptr<ReportManagement::DbHandler> m_dbHandler;
|
||||
std::shared_ptr<ReportManagement::DatabaseInterface> m_db;
|
||||
|
||||
qint32 m_exerciseId;
|
||||
int m_testId;
|
||||
int m_reportId;
|
||||
int m_operatorId;
|
||||
bool m_bTestsSuccessful;
|
||||
|
||||
LOGGER_T m_logger;
|
||||
};
|
||||
|
||||
} // namespace
|
||||
Reference in new issue
Block a user