Skip to content

Commit

Permalink
[auth] Skip unit tests if qca-ossl plugin is missing
Browse files Browse the repository at this point in the history
  • Loading branch information
dakcarto committed Sep 26, 2015
1 parent 05a28b8 commit dd9b37b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 3 additions & 0 deletions tests/src/core/testqgsauthconfig.cpp
Expand Up @@ -19,6 +19,7 @@
#include <QStringList>

#include "qgsapplication.h"
#include "qgsauthcrypto.h"
#include "qgsauthconfig.h"

/** \ingroup UnitTests
Expand Down Expand Up @@ -50,6 +51,8 @@ void TestQgsAuthConfig::initTestCase()
{
QgsApplication::init();
QgsApplication::initQgis();
if ( QgsAuthCrypto::isDisabled() )
QSKIP( "QCA's qca-ossl plugin is missing, skipping test case", SkipAll );
}

void TestQgsAuthConfig::cleanupTestCase()
Expand Down
3 changes: 2 additions & 1 deletion tests/src/core/testqgsauthcrypto.cpp
Expand Up @@ -82,7 +82,8 @@ void TestQgsAuthCrypto::initTestCase()
{
QgsApplication::init();
QgsApplication::initQgis();
QVERIFY2( !QgsAuthCrypto::isDisabled(), "QCA's qca-ossl plugin is missing, skipping test" );
if ( QgsAuthCrypto::isDisabled() )
QSKIP( "QCA's qca-ossl plugin is missing, skipping test case", SkipAll );
}

void TestQgsAuthCrypto::cleanupTestCase()
Expand Down

0 comments on commit dd9b37b

Please sign in to comment.