Files
pilotclient/tests/blackgui/testguiutility/testguiutility.cpp
Roland Winklmeier 77ce9f8b8a Split the giant test binaries into smaller unit tests
This is an intermediate step to have smaller unit tests. It is a trade off
between having many many test executables compared to a few bigger ones. But
this comes a lot closer to what QtTest is meant to be used.
2018-08-25 22:12:01 +02:00

45 lines
1.2 KiB
C++

/* Copyright (C) 2015
* swift project Community / Contributors
*
* This file is part of swift project. It is subject to the license terms in the LICENSE file found in the top-level
* directory of this distribution and at http://www.swift-project.org/license.html. No part of swift project,
* including this file, may be copied, modified, propagated, or distributed except according to the terms
* contained in the LICENSE file.
*/
//! \cond PRIVATE_TESTS
//! \file
//! \ingroup testblackgui
#include "blackgui/guiutility.h"
#include "test.h"
using namespace BlackGui;
namespace BlackGuiTest
{
//! Test GUI utilities
class CTestGuiUtility : public QObject
{
Q_OBJECT
private slots:
//! Test the lenientTitleComparison
void testLenientTitleComparison();
};
void CTestGuiUtility::testLenientTitleComparison()
{
QVERIFY2(CGuiUtility::lenientTitleComparison("foo", "foo"), "wrong title match");
QVERIFY2(CGuiUtility::lenientTitleComparison("foo&", "&Foo"), "wrong title match");
QVERIFY2(!CGuiUtility::lenientTitleComparison("foo", "bar"), "wrong title mismatch");
}
} // ns
//! main
BLACKTEST_APPLESS_MAIN(BlackGuiTest::CTestGuiUtility);
#include "testguiutility.moc"
//! \endcond