aboutsummaryrefslogtreecommitdiff
path: root/src/client/windows/unittests
diff options
context:
space:
mode:
authorted.mielczarek <ted.mielczarek@4c0a9323-5329-0410-9bdc-e9ce6186880e>2011-11-11 19:05:51 +0000
committerted.mielczarek <ted.mielczarek@4c0a9323-5329-0410-9bdc-e9ce6186880e>2011-11-11 19:05:51 +0000
commit06cede988b4d15b4d6b7e759fda676bfe3455682 (patch)
treefbe6cc1e33d29d251cf912aac1f35a5e7d823274 /src/client/windows/unittests
parent Correct leak. (diff)
downloadbreakpad-06cede988b4d15b4d6b7e759fda676bfe3455682.tar.xz
Allow CrashGenerationClient to request that a dump of the parent process be written.
A=Jim Mathies <jmathies@mozilla.com> R=ted at https://bugzilla.mozilla.org/show_bug.cgi?id=679238 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@883 4c0a9323-5329-0410-9bdc-e9ce6186880e
Diffstat (limited to 'src/client/windows/unittests')
-rw-r--r--src/client/windows/unittests/crash_generation_server_test.cc7
-rw-r--r--src/client/windows/unittests/exception_handler_death_test.cc1
-rw-r--r--src/client/windows/unittests/exception_handler_test.cc2
3 files changed, 8 insertions, 2 deletions
diff --git a/src/client/windows/unittests/crash_generation_server_test.cc b/src/client/windows/unittests/crash_generation_server_test.cc
index ce49439c..01dda951 100644
--- a/src/client/windows/unittests/crash_generation_server_test.cc
+++ b/src/client/windows/unittests/crash_generation_server_test.cc
@@ -77,8 +77,9 @@ class CrashGenerationServerTest : public ::testing::Test {
public:
MOCK_METHOD1(OnClientConnected,
void(const google_breakpad::ClientInfo* client_info));
- MOCK_METHOD2(OnClientDumpRequested,
+ MOCK_METHOD3(OnClientDumpRequested,
void(const google_breakpad::ClientInfo* client_info,
+ const google_breakpad::CrashGenerationServer::ClientDumpRequestType request_type,
const std::wstring* file_path));
MOCK_METHOD1(OnClientExited,
void(const google_breakpad::ClientInfo* client_info));
@@ -176,6 +177,7 @@ class CrashGenerationServerTest : public ::testing::Test {
custom_info,
NULL,
NULL,
+ NULL,
NULL);
DWORD bytes_count = 0;
@@ -237,9 +239,10 @@ class CrashGenerationServerTest : public ::testing::Test {
static void CallOnClientDumpRequested(
void* context,
const google_breakpad::ClientInfo* client_info,
+ const google_breakpad::CrashGenerationServer::ClientDumpRequestType request_type,
const std::wstring* file_path) {
static_cast<MockCrashGenerationServerCallbacks*>(context)->
- OnClientDumpRequested(client_info, file_path);
+ OnClientDumpRequested(client_info, request_type, file_path);
}
static void CallOnClientExited(
diff --git a/src/client/windows/unittests/exception_handler_death_test.cc b/src/client/windows/unittests/exception_handler_death_test.cc
index adea044f..bac96def 100644
--- a/src/client/windows/unittests/exception_handler_death_test.cc
+++ b/src/client/windows/unittests/exception_handler_death_test.cc
@@ -131,6 +131,7 @@ static bool gDumpCallbackCalled = false;
void clientDumpCallback(void *dump_context,
const google_breakpad::ClientInfo *client_info,
+ const google_breakpad::CrashGenerationServer::ClientDumpRequestType request_type,
const std::wstring *dump_path) {
gDumpCallbackCalled = true;
}
diff --git a/src/client/windows/unittests/exception_handler_test.cc b/src/client/windows/unittests/exception_handler_test.cc
index f0341880..18aeded7 100644
--- a/src/client/windows/unittests/exception_handler_test.cc
+++ b/src/client/windows/unittests/exception_handler_test.cc
@@ -78,6 +78,7 @@ class ExceptionHandlerTest : public ::testing::Test {
static void ClientDumpCallback(
void *dump_context,
const google_breakpad::ClientInfo *client_info,
+ const google_breakpad::CrashGenerationServer::ClientDumpRequestType request_type,
const std::wstring *dump_path);
static bool DumpCallback(const wchar_t* dump_path,
@@ -138,6 +139,7 @@ BOOL ExceptionHandlerTest::DoesPathExist(const TCHAR *path_name) {
void ExceptionHandlerTest::ClientDumpCallback(
void *dump_context,
const google_breakpad::ClientInfo *client_info,
+ const google_breakpad::CrashGenerationServer::ClientDumpRequestType request_type,
const wstring *dump_path) {
dump_file = *dump_path;
// Create the full dump file name from the dump path.