diff --git a/tests/auto/cplusplus/findusages/tst_findusages.cpp b/tests/auto/cplusplus/findusages/tst_findusages.cpp
index ae05c3d36ea5e74565e6ab473d7d507520dadcbc..9ab9d41af843ba0e04c44a2aa1b2112efe220a3b 100644
--- a/tests/auto/cplusplus/findusages/tst_findusages.cpp
+++ b/tests/auto/cplusplus/findusages/tst_findusages.cpp
@@ -75,6 +75,9 @@ class tst_FindUsages: public QObject
 {
     Q_OBJECT
 
+private:
+    void dump(const QList<Usage> &usages) const;
+
 private Q_SLOTS:
     void inlineMethod();
     void lambdaCaptureByValue();
@@ -107,6 +110,20 @@ private Q_SLOTS:
     void templatedFunction_QTCREATORBUG9749();
 };
 
+void tst_FindUsages::dump(const QList<Usage> &usages) const
+{
+    QTextStream err(stderr, QIODevice::WriteOnly);
+    err << "DEBUG  : " << usages.size() << " usages:" << endl;
+    foreach (const Usage &usage, usages) {
+        err << "DEBUG  : "
+            << usage.path << ":"
+            << usage.line << ":"
+            << usage.col << ":"
+            << usage.len << ":"
+            << usage.lineText << endl;
+    }
+}
+
 void tst_FindUsages::inlineMethod()
 {
     const QByteArray src = "\n"