Add a comment to tst_qtimer.cpp to point out its reuse by QtGui
The same test code is compiled by two different modules' tests, which won't be obvious to the reader of the code unless it's pointed out explicitly. Change-Id: I99dba6eb186939c372636c5c1fc29799003d32a7 Reviewed-by: Ivan Solovev <ivan.solovev@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
parent
305c8e9cf0
commit
9f3ae15933
@ -2,9 +2,19 @@
|
||||
// Copyright (C) 2016 Intel Corporation.
|
||||
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
|
||||
|
||||
/* WARNING: this source-code is reused by another test.
|
||||
|
||||
As Qt built with GUI support may use a different backend for its event loops
|
||||
and other timer-related matters, it is important to test it in that form, as
|
||||
well as in its GUI-less form. So this source file is reused by a build config
|
||||
in the GUI module. Similarly, testing with and without glib is supported,
|
||||
where relevant (see DISABLE_GLIB below).
|
||||
*/
|
||||
#ifdef QT_GUI_LIB
|
||||
// When compiled as tests/auto/gui/kernel/qguitimer/'s source-code:
|
||||
# include <QtGui/QGuiApplication>
|
||||
#else
|
||||
// When compiled as tests/auto/corelib/kernel/qtimer/'s source-code:
|
||||
# include <QtCore/QCoreApplication>
|
||||
#endif
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user