Merge pull request #72 from QuasarApp/task_61

Added implementations of a file worker interface.
This commit is contained in:
Andrei Yankovich 2022-05-17 09:15:24 +03:00 committed by GitHub
commit 877d3dcb21
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 140 additions and 0 deletions

View File

@ -0,0 +1,28 @@
//#
//# Copyright (C) 2021-2021 QuasarApp.
//# Distributed under the lgplv3 software license, see the accompanying
//# Everyone is permitted to copy and distribute verbatim copies
//# of this license document, but changing it is not allowed.
//#
#include "interfaceimplem.h"
namespace CopyrighFixer {
InterfaceImplem::InterfaceImplem() {
}
bool InterfaceImplem::read(const QString &pathToFile, Signature &objSign) {
}
bool InterfaceImplem::write(const QString &pathToFile, const Signature &objSign) {
}
Extension InterfaceImplem::supportsExtensions() const {
}
};

View File

@ -0,0 +1,32 @@
//#
//# Copyright (C) 2021-2021 QuasarApp.
//# Distributed under the lgplv3 software license, see the accompanying
//# Everyone is permitted to copy and distribute verbatim copies
//# of this license document, but changing it is not allowed.
//#
#ifndef INTERFACEIMPLEM_H
#define INTERFACEIMPLEM_H
#include "CopyrighFixer_global.h"
#include "CopyrighFixer/ifilemanager.h"
namespace CopyrighFixer {
class CopyrighFixer_EXPORT InterfaceImplem: public IFileManager {
public:
InterfaceImplem();
bool read(const QString &pathToFile, Signature &objSign);
bool write(const QString &pathToFile, const Signature &objSign);
Extension supportsExtensions() const;
};
};
#endif // INTERFACEIMPLEM_H

View File

@ -0,0 +1,6 @@
#include "interfaceimplem.h"
InterfaceImplem::InterfaceImplem()
{
}

View File

@ -0,0 +1,11 @@
#ifndef INTERFACEIMPLEM_H
#define INTERFACEIMPLEM_H
class InterfaceImplem
{
public:
InterfaceImplem();
};
#endif // INTERFACEIMPLEM_H

View File

@ -10,6 +10,7 @@
#include "signtest.h"
#include "signertest.h"
#include "configparsertest.h"
#include "interfaceimplemtest.h"
// Use This macros for initialize your own test classes.
// Check exampletests
@ -37,6 +38,7 @@ private slots:
TestCase(signTest, SignTest);
TestCase(signerTest, SignerTest);
TestCase(configParserTest, ConfigParserTest)
TestCase(interfaceImplemTest, InterfaceImplemTest)
// END TEST CASES
private:

View File

@ -0,0 +1,33 @@
//#
//# Copyright (C) 2020-2021 QuasarApp.
//# Distributed under the lgplv3 software license, see the accompanying
//# Everyone is permitted to copy and distribute verbatim copies
//# of this license document, but changing it is not allowed.
//#
#include "interfaceimplemtest.h"
InterfaceImplemTest::InterfaceImplemTest() {
}
InterfaceImplemTest::~InterfaceImplemTest() {
}
void InterfaceImplemTest::test() {
testIntesfaceImplem();
}
void InterfaceImplemTest::testReadSign() {
QVERIFY(true);
}
void InterfaceImplemTest::testWriteSign() {
QVERIFY(true);
}
void InterfaceImplemTest::testIntesfaceImplem() {
testReadSign();
testWriteSign();
}

View File

@ -0,0 +1,28 @@
//#
//# Copyright (C) 2020-2021 QuasarApp.
//# Distributed under the lgplv3 software license, see the accompanying
//# Everyone is permitted to copy and distribute verbatim copies
//# of this license document, but changing it is not allowed.
//#
#ifndef INTERFACEIMPLEMTEST_H
#define INTERFACEIMPLEMTEST_H
#include "test.h"
#include "testutils.h"
#include "CopyrighFixer/interfaceimplem.h"
#include <QTest>
class InterfaceImplemTest: public Test, protected TestUtils {
public:
InterfaceImplemTest();
~InterfaceImplemTest();
void test();
void testReadSign();
void testWriteSign();
void testIntesfaceImplem();
};
#endif // INTERFACEIMPLEMTEST_H