50 lines
1.6 KiB
C++
Executable File
50 lines
1.6 KiB
C++
Executable File
/**
|
|
* @RDE_HEADER@
|
|
* AES Function Topic Client test executable
|
|
* $Id$
|
|
* $HeadURL$
|
|
* $Author$
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include "aes_test_base.h"
|
|
|
|
namespace AreaEffectSimulation
|
|
{
|
|
class TestExplosionAreaBulk final : public TestBase
|
|
, protected AreaEffectSimulation::Interface::Ftc::ExplosionAreaModifyReplyHandler
|
|
, protected AreaEffectSimulation::Interface::Ftc::ExplosionAreaPauseResumeReplyHandler
|
|
{
|
|
Q_OBJECT
|
|
public:
|
|
explicit TestExplosionAreaBulk(QObject *parent = nullptr);
|
|
|
|
bool init(int domainId, int exerciseId, int testId) override;
|
|
public Q_SLOTS:
|
|
void startTest() override { tryCreateExplosionArea(); }
|
|
private Q_SLOTS:
|
|
void tryCreateExplosionArea();
|
|
void tryModifyExplosionArea();
|
|
void tryWaitForActivationExplosionArea();
|
|
void tryPauseResumeExplosionArea();
|
|
void checkTriggeredExplosions();
|
|
void checkTriggeredExplosionsHelper(int bitfield);
|
|
protected Q_SLOTS:
|
|
void explosionAreaChanged(const AreaEffectSimulation::ExplosionArea &data, DataModification modType);
|
|
void triggeredImpactsChanged(const AreaEffectSimulation::TriggeredImpacts &data, DataModification modType);
|
|
protected:
|
|
void onExplosionAreaModifyReply(const Core::FunctionReplyObject &replyObject) override;
|
|
void onExplosionAreaPauseResumeReply(const Core::FunctionReplyObject &replyObject) override;
|
|
|
|
private:
|
|
bool checkBaseData(const AreaEffectSimulation::ExplosionArea &a,
|
|
const AreaEffectSimulation::ExplosionArea &b) const;
|
|
|
|
private:
|
|
AreaEffectSimulation::ExplosionArea m_eaData;
|
|
AreaEffectSimulation::TriggeredImpacts m_tiData;
|
|
};
|
|
|
|
} // namespace AreaEffectSimulation
|