mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
c8133fee65
--HG-- rename : ipc/ipdl/test/cxx/PTestRPCErrorCleanup.ipdl => ipc/ipdl/test/cxx/PTestInterruptErrorCleanup.ipdl rename : ipc/ipdl/test/cxx/PTestRPCRaces.ipdl => ipc/ipdl/test/cxx/PTestInterruptRaces.ipdl rename : ipc/ipdl/test/cxx/PTestRPCShutdownRace.ipdl => ipc/ipdl/test/cxx/PTestInterruptShutdownRace.ipdl rename : ipc/ipdl/test/cxx/PTestRacyRPCReplies.ipdl => ipc/ipdl/test/cxx/PTestRacyInterruptReplies.ipdl rename : ipc/ipdl/test/cxx/TestRPCErrorCleanup.cpp => ipc/ipdl/test/cxx/TestInterruptErrorCleanup.cpp rename : ipc/ipdl/test/cxx/TestRPCErrorCleanup.h => ipc/ipdl/test/cxx/TestInterruptErrorCleanup.h rename : ipc/ipdl/test/cxx/TestRPCRaces.cpp => ipc/ipdl/test/cxx/TestInterruptRaces.cpp rename : ipc/ipdl/test/cxx/TestRPCRaces.h => ipc/ipdl/test/cxx/TestInterruptRaces.h rename : ipc/ipdl/test/cxx/TestRPCShutdownRace.cpp => ipc/ipdl/test/cxx/TestInterruptShutdownRace.cpp rename : ipc/ipdl/test/cxx/TestRPCShutdownRace.h => ipc/ipdl/test/cxx/TestInterruptShutdownRace.h rename : ipc/ipdl/test/cxx/TestRacyRPCReplies.cpp => ipc/ipdl/test/cxx/TestRacyInterruptReplies.cpp rename : ipc/ipdl/test/cxx/TestRacyRPCReplies.h => ipc/ipdl/test/cxx/TestRacyInterruptReplies.h rename : ipc/ipdl/test/ipdl/error/rpcMessageCompress.ipdl => ipc/ipdl/test/ipdl/error/intrMessageCompress.ipdl rename : ipc/ipdl/test/ipdl/error/tooWeakRPCAsync.ipdl => ipc/ipdl/test/ipdl/error/tooWeakInterruptAsync.ipdl rename : ipc/ipdl/test/ipdl/ok/rpcProtocol.ipdl => ipc/ipdl/test/ipdl/ok/intrProtocol.ipdl
74 lines
1.6 KiB
C++
74 lines
1.6 KiB
C++
#ifndef mozilla__ipdltest_TestRacyInterruptReplies_h
|
|
#define mozilla__ipdltest_TestRacyInterruptReplies_h 1
|
|
|
|
#include "mozilla/_ipdltest/IPDLUnitTests.h"
|
|
|
|
#include "mozilla/_ipdltest/PTestRacyInterruptRepliesParent.h"
|
|
#include "mozilla/_ipdltest/PTestRacyInterruptRepliesChild.h"
|
|
|
|
namespace mozilla {
|
|
namespace _ipdltest {
|
|
|
|
|
|
class TestRacyInterruptRepliesParent :
|
|
public PTestRacyInterruptRepliesParent
|
|
{
|
|
public:
|
|
TestRacyInterruptRepliesParent();
|
|
virtual ~TestRacyInterruptRepliesParent();
|
|
|
|
static bool RunTestInProcesses() { return true; }
|
|
static bool RunTestInThreads() { return true; }
|
|
|
|
void Main();
|
|
|
|
protected:
|
|
virtual bool RecvA_() MOZ_OVERRIDE;
|
|
|
|
virtual bool Answer_R(int* replyNum) MOZ_OVERRIDE;
|
|
|
|
virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE
|
|
{
|
|
if (NormalShutdown != why)
|
|
fail("unexpected destruction!");
|
|
passed("ok");
|
|
QuitParent();
|
|
}
|
|
|
|
private:
|
|
int mReplyNum;
|
|
};
|
|
|
|
|
|
class TestRacyInterruptRepliesChild :
|
|
public PTestRacyInterruptRepliesChild
|
|
{
|
|
public:
|
|
TestRacyInterruptRepliesChild();
|
|
virtual ~TestRacyInterruptRepliesChild();
|
|
|
|
protected:
|
|
virtual bool AnswerR_(int* replyNum) MOZ_OVERRIDE;
|
|
|
|
virtual bool RecvChildTest() MOZ_OVERRIDE;
|
|
|
|
virtual bool Recv_A() MOZ_OVERRIDE;
|
|
|
|
virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE
|
|
{
|
|
if (NormalShutdown != why)
|
|
fail("unexpected destruction!");
|
|
QuitChild();
|
|
}
|
|
|
|
private:
|
|
int mReplyNum;
|
|
};
|
|
|
|
|
|
} // namespace _ipdltest
|
|
} // namespace mozilla
|
|
|
|
|
|
#endif // ifndef mozilla__ipdltest_TestRacyInterruptReplies_h
|