refs #441 Rename COriginator to CIdentifier and rename COriginatorAware to CIdentifiable.

This commit is contained in:
Mathew Sutcliffe
2015-06-05 12:57:40 +01:00
parent a4ca75c5c7
commit d4d862927e
90 changed files with 503 additions and 500 deletions

View File

@@ -0,0 +1,39 @@
/* Copyright (C) 2013
* 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.
*/
#include "testidentifier.h"
#include "blackmisc/blackmiscfreefunctions.h"
#include "blackmisc/identifierlist.h"
using namespace BlackMisc;
namespace BlackMiscTest
{
void CTestIdentifier::identifierBasics()
{
CIdentifier o1;
CIdentifier o2;
CIdentifier o3("foobar");
QVERIFY2(o1 == o2, "Two default identifiers shall be equal");
QVERIFY2(o1 != o3, "Those identifiers shall be unequal");
// test object name change
QObject q;
q.setObjectName("foo");
CTestIdentifiable oa(&q);
QVERIFY2(oa.identifier().getName() == q.objectName(), "Names shall be equal");
q.setObjectName("bar");
QVERIFY2(oa.identifier().getName() == q.objectName(), "Names shall be equal");
}
CTestIdentifiable::CTestIdentifiable(QObject *nameObject) : CIdentifiable(nameObject)
{ }
} //namespace