Skip to content

Commit

Permalink
Fixes: failing unit tests
Browse files Browse the repository at this point in the history
RevBy: TrustMe
  • Loading branch information
palehtin committed Dec 12, 2011
1 parent eeaa58d commit c298d24
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
8 changes: 5 additions & 3 deletions tests/ut_notificationareasink/ut_notificationareasink.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,13 @@
#include "notificationgroup_stub.h"
#include "notificationmanager_stub.h"


static char *gAppName = (char *)"./ut_notificationareasink";

// QCoreApplication stubs to avoid crashing in processEvents()
QStringList QCoreApplication::arguments()
{
return QStringList();
return QStringList(gAppName);
}

// MGConfItem stubs
Expand Down Expand Up @@ -147,8 +150,7 @@ void Ut_NotificationAreaSink::initTestCase()
{
// Create a MAapplication
static int argc = 1;
static char *app_name = (char *)"./ut_notificationareasink";
app = new MApplication(argc, &app_name);
app = new MApplication(argc, &gAppName);
}

void Ut_NotificationAreaSink::cleanupTestCase()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,19 +32,20 @@ TestNotificationParameters::TestNotificationParameters(const QString &image, con
}
}

static char *gAppName = (char *)"./ut_notificationstatusindicatorsink";

// QCoreApplication stubs to avoid crashing in processEvents()
QStringList QCoreApplication::arguments()
{
return QStringList();
return QStringList(gAppName);
}

// Tests
void Ut_NotificationStatusIndicatorSink::initTestCase()
{
// Create a MAapplication
static int argc = 1;
static char *app_name = (char *)"./ut_notificationstatusindicatorsink";
app = new MApplication(argc, &app_name);
app = new MApplication(argc, &gAppName);
}

void Ut_NotificationStatusIndicatorSink::cleanupTestCase()
Expand Down

0 comments on commit c298d24

Please sign in to comment.