Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
KDE Pim
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Unmaintained
KDE Pim
Commits
558f3588
Commit
558f3588
authored
Jul 08, 2014
by
Laurent Montel
😁
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Port test to qt5
parent
5f245ee6
Changes
14
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
30 additions
and
26 deletions
+30
-26
agents/followupreminderagent/tests/CMakeLists.txt
agents/followupreminderagent/tests/CMakeLists.txt
+3
-1
agents/followupreminderagent/tests/followupreminderinfotest.cpp
.../followupreminderagent/tests/followupreminderinfotest.cpp
+2
-2
kmail/tests/CMakeLists.txt
kmail/tests/CMakeLists.txt
+3
-1
knotes/CMakeLists.txt
knotes/CMakeLists.txt
+1
-1
knotes/tests/CMakeLists.txt
knotes/tests/CMakeLists.txt
+3
-5
knotes/tests/apps/knotesakonadiapp.cpp
knotes/tests/apps/knotesakonadiapp.cpp
+2
-0
knotes/tests/apps/knotesakonaditray.cpp
knotes/tests/apps/knotesakonaditray.cpp
+1
-1
knotes/tests/apps/knotesakonaditray.h
knotes/tests/apps/knotesakonaditray.h
+2
-1
knotes/tests/notetest.cpp
knotes/tests/notetest.cpp
+2
-2
messagelist/tests/itemsizetest.cpp
messagelist/tests/itemsizetest.cpp
+2
-2
messagelist/tests/quicksearchlinetest.cpp
messagelist/tests/quicksearchlinetest.cpp
+3
-4
pimcommon/texteditor/commonwidget/tests/textgotolinewidgettest.cpp
.../texteditor/commonwidget/tests/textgotolinewidgettest.cpp
+3
-2
pimcommon/translator/tests/translatortest.cpp
pimcommon/translator/tests/translatortest.cpp
+3
-3
templateparser/tests/CMakeLists.txt
templateparser/tests/CMakeLists.txt
+0
-1
No files found.
agents/followupreminderagent/tests/CMakeLists.txt
View file @
558f3588
...
...
@@ -8,7 +8,9 @@ include_directories( ${CMAKE_CURRENT_SOURCE_DIR}/.. ${CMAKE_CURRENT_SOURCE_DIR}/
macro
(
followupreminder_agent _source
)
set
(
_test
${
_source
}
)
get_filename_component
(
_name
${
_source
}
NAME_WE
)
kde4_add_unit_test
(
${
_name
}
TESTNAME followupreminder-
${
_name
}
${
_test
}
)
add_executable
(
${
_name
}
${
_test
}
)
add_test
(
${
_name
}
${
_name
}
)
ecm_mark_as_test
(
followupreminder-
${
_name
}
)
target_link_libraries
(
${
_name
}
Qt5::Test KF5::AkonadiCore followupreminder
)
endmacro
()
...
...
agents/followupreminderagent/tests/followupreminderinfotest.cpp
View file @
558f3588
...
...
@@ -17,7 +17,7 @@
#include "followupreminderinfotest.h"
#include "../followupreminderinfo.h"
#include <qtest
_kde
.h>
#include <qtest.h>
FollowUpReminderInfoTest
::
FollowUpReminderInfoTest
()
{
...
...
@@ -51,4 +51,4 @@ void FollowUpReminderInfoTest::shoudBeNotValid()
QCOMPARE
(
info
.
isValid
(),
true
);
}
QTEST_
KDEMAIN
(
FollowUpReminderInfoTest
,
NoGUI
)
QTEST_
MAIN
(
FollowUpReminderInfoTest
)
kmail/tests/CMakeLists.txt
View file @
558f3588
...
...
@@ -14,6 +14,8 @@ target_link_libraries(dbustest KF5::KIOCore KF5::KDELibs4Support)
set
(
kmail_displaymenu_source displaymessageformatactionmenutest.cpp ../widgets/displaymessageformatactionmenu.cpp
)
kde4_add_unit_test
(
displaymessageformatactionmenutest
${
kmail_displaymenu_source
}
)
add_executable
(
displaymessageformatactionmenutest
${
kmail_displaymenu_source
}
)
add_test
(
displaymessageformatactionmenutest displaymessageformatactionmenutest
)
ecm_mark_as_test
(
kmail-displaymessageformatactionmenutest
)
target_link_libraries
(
displaymessageformatactionmenutest Qt5::Test messageviewer
)
knotes/CMakeLists.txt
View file @
558f3588
project
(
knotes
)
add_subdirectory
(
icons
)
#
add_subdirectory( tests )
add_subdirectory
(
tests
)
add_definitions
(
-DQT_NO_CAST_FROM_ASCII
)
add_definitions
(
-DQT_NO_CAST_TO_ASCII
)
...
...
knotes/tests/CMakeLists.txt
View file @
558f3588
...
...
@@ -2,17 +2,15 @@ add_subdirectory(apps)
set
(
EXECUTABLE_OUTPUT_PATH
${
CMAKE_CURRENT_BINARY_DIR
}
)
include_directories
(
)
include
(
${
CMAKE_SOURCE_DIR
}
/cmake/modules/kde4_handle_crypto_rpath_for_executable.cmake
)
# convenience macro to add qtest unit tests
macro
(
add_knotes_unittest _source
)
set
(
_test
${
_source
}
)
get_filename_component
(
_name
${
_source
}
NAME_WE
)
kde4_add_unit_test
(
${
_name
}
TESTNAME knotes-
${
_name
}
${
_test
}
)
add_executable
(
${
_name
}
${
_test
}
)
add_test
(
${
_name
}
${
_name
}
)
ecm_mark_as_test
(
knotes-
${
_name
}
)
target_link_libraries
(
${
_name
}
Qt5::Test
KF5::KIOCore
...
...
knotes/tests/apps/knotesakonadiapp.cpp
View file @
558f3588
...
...
@@ -34,6 +34,8 @@
#include <QDebug>
#include <QHash>
#include <QTextEdit>
#include <QLineEdit>
KNotesAkonadiApp
::
KNotesAkonadiApp
(
QWidget
*
parent
)
:
QWidget
(
parent
)
...
...
knotes/tests/apps/knotesakonaditray.cpp
View file @
558f3588
...
...
@@ -30,7 +30,7 @@
KNotesAkonadiTray
::
KNotesAkonadiTray
(
Akonadi
::
ChangeRecorder
*
recorder
,
QWidget
*
parent
)
:
KStatusNotifierItem
(
parent
),
mIcon
(
Q
Latin1String
(
"knotes"
))
mIcon
(
Q
Icon
::
fromTheme
(
QLatin1String
(
"knotes"
)
))
{
setToolTipTitle
(
i18n
(
"KNotes: Sticky notes for KDE"
)
);
setToolTipIconByName
(
QLatin1String
(
"knotes"
)
);
...
...
knotes/tests/apps/knotesakonaditray.h
View file @
558f3588
...
...
@@ -19,6 +19,7 @@
#define KNOTESAKONADITRAY_H
#include <KStatusNotifierItem>
#include <QIcon>
namespace
Akonadi
{
class
ChangeRecorder
;
}
...
...
@@ -35,7 +36,7 @@ private Q_SLOTS:
void
slotUpdateSystemTray
();
private:
K
Icon
mIcon
;
Q
Icon
mIcon
;
};
#endif // KNOTESAKONADITRAY_H
knotes/tests/notetest.cpp
View file @
558f3588
...
...
@@ -16,11 +16,11 @@
*/
#include "notetest.h"
#include <qtest
_kde
.h>
#include <qtest.h>
NoteTest
::
NoteTest
()
{
}
QTEST_
KDEMAIN
(
NoteTest
,
GUI
)
QTEST_
MAIN
(
NoteTest
)
messagelist/tests/itemsizetest.cpp
View file @
558f3588
...
...
@@ -19,7 +19,7 @@
#include "../core/messageitem_p.h"
#include <qtest
_kde
.h>
#include <qtest.h>
#include <QObject>
using
namespace
MessageList
::
Core
;
...
...
@@ -42,6 +42,6 @@ class ItemSizeTest : public QObject
}
};
QTEST_
KDEMAIN
(
ItemSizeTest
,
GUI
)
QTEST_
MAIN
(
ItemSizeTest
)
#include "itemsizetest.moc"
messagelist/tests/quicksearchlinetest.cpp
View file @
558f3588
...
...
@@ -21,15 +21,14 @@
#include "quicksearchlinetest.h"
#include "messagelist/core/quicksearchline.h"
#include <qtest
_kde
.h>
#include <qtest.h>
#include <qtestkeyboard.h>
#include <qtestmouse.h>
#include <KLineEdit>
#include <QToolButton>
#include <QPushButton>
#include <QPushButton>
#include <KComboBox>
#include <QSignalSpy>
using
namespace
MessageList
::
Core
;
QuickSearchLineTest
::
QuickSearchLineTest
()
...
...
@@ -280,4 +279,4 @@ void QuickSearchLineTest::shouldNotShowComboboxWhenWeAddNewItemWhenWeHiddedQuick
}
QTEST_
KDEMAIN
(
QuickSearchLineTest
,
GUI
)
QTEST_
MAIN
(
QuickSearchLineTest
)
pimcommon/texteditor/commonwidget/tests/textgotolinewidgettest.cpp
View file @
558f3588
...
...
@@ -18,7 +18,8 @@
#include "textgotolinewidgettest.h"
#include "pimcommon/texteditor/commonwidget/textgotolinewidget.h"
#include <qtest_kde.h>
#include <qtest.h>
#include <QSignalSpy>
#include <qtestmouse.h>
#include <qtestkeyboard.h>
#include <QSpinBox>
...
...
@@ -130,4 +131,4 @@ void TextGoToLineWidgetTest::shouldSetFocusWhenWeRecallGotToLine()
}
QTEST_
KDEMAIN
(
TextGoToLineWidgetTest
,
GUI
)
QTEST_
MAIN
(
TextGoToLineWidgetTest
)
pimcommon/translator/tests/translatortest.cpp
View file @
558f3588
...
...
@@ -21,11 +21,11 @@
#include <QPushButton>
#include <qtest
_kde
.h>
#include <qtest.h>
#include <qtestkeyboard.h>
#include <qtestmouse.h>
#include <QComboBox>
#include <QSignalSpy>
TranslatorTest
::
TranslatorTest
()
{
...
...
@@ -118,4 +118,4 @@ void TranslatorTest::shouldEmitTranslatorWasClosedSignalWhenCloseIt()
QCOMPARE
(
spy
.
count
(),
1
);
}
QTEST_
KDEMAIN
(
TranslatorTest
,
GUI
)
QTEST_
MAIN
(
TranslatorTest
)
templateparser/tests/CMakeLists.txt
View file @
558f3588
...
...
@@ -20,7 +20,6 @@ macro(add_templateparser_unittest _source)
messageviewer
${
QGPGME_LIBRARIES
}
Qt5::Test
Qt5::WebKitWidgets
KF5::KIOCore
KF5::Mime
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment