Skip to content

Commit

Permalink
QMimeDatabase: only export var for unittests if QT_BUILD_INTERNAL
Browse files Browse the repository at this point in the history
Change-Id: I7fa25b64cf39667c8cea95431f68baab623c8a2a
Reviewed-by: Thiago Macieira <[email protected]>
  • Loading branch information
dfaure-kdab committed Jan 2, 2018
1 parent 7396112 commit bb6f0a5
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/corelib/mimetypes/qmimedatabase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,12 @@ QMimeDatabasePrivate::~QMimeDatabasePrivate()
qDeleteAll(m_providers);
}

Q_CORE_EXPORT int qmime_secondsBetweenChecks = 5; // exported for the unit test
#ifdef QT_BUILD_INTERNAL
Q_CORE_EXPORT
#else
static const
#endif
int qmime_secondsBetweenChecks = 5;

bool QMimeDatabasePrivate::shouldCheck()
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
CONFIG += testcase

requires(qtConfig(private_tests))

TARGET = tst_qmimedatabase-cache

QT = core testlib concurrent
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
CONFIG += testcase

requires(qtConfig(private_tests))

TARGET = tst_qmimedatabase-xml

QT = core testlib concurrent
Expand Down

0 comments on commit bb6f0a5

Please sign in to comment.