UnitTests: Fix names and disable slow tests by default

Slow and very slow tests have now their own test category. We add SlowTest
for tests which are slower than ~5ms and VerySlowTest if they are slower
than ~100ms. They are disabled them by "-*SlowTest.*". If you have a faster
machine than most developers simply try lower values. The aim is that most
developers can execute the tests in under ~2s.

In the long run we should use dependency breaking and data sharing to
reduce the count of the slow tests.

Change-Id: I8578071258d7f89b2052709f3dd526ced811483f
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
This commit is contained in:
Marco Bubke
2017-01-04 11:39:17 +01:00
parent 719e6e0aff
commit ada5ea1952
27 changed files with 319 additions and 272 deletions

View File

@@ -78,6 +78,8 @@ protected:
dummyIpcClient};
};
using DocumentProcessorsSlowTest = DocumentProcessors;
TEST_F(DocumentProcessors, HasNoItemsInitially)
{
ASSERT_TRUE(documentProcessors.processors().empty());
@@ -144,7 +146,7 @@ TEST_F(DocumentProcessors, ProcessEmpty)
ASSERT_TRUE(jobsStarted.isEmpty());
}
TEST_F(DocumentProcessors, ProcessSingle)
TEST_F(DocumentProcessorsSlowTest, ProcessSingle)
{
DocumentProcessor documentProcessor = documentProcessors.create(document);
const JobRequest jobRequest = createJobRequest(JobRequest::Type::UpdateDocumentAnnotations);