mirror of
https://github.com/QuasarApp/CopyrightFixer.git
synced 2025-04-26 01:34:40 +00:00
Merge pull request #72 from QuasarApp/task_61
Added implementations of a file worker interface.
This commit is contained in:
commit
877d3dcb21
28
src/CopyrighFixer/CopyrighFixer/interfaceimplem.cpp
Normal file
28
src/CopyrighFixer/CopyrighFixer/interfaceimplem.cpp
Normal 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 {
|
||||
|
||||
}
|
||||
|
||||
};
|
32
src/CopyrighFixer/CopyrighFixer/interfaceimplem.h
Normal file
32
src/CopyrighFixer/CopyrighFixer/interfaceimplem.h
Normal 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
|
6
src/CopyrighFixer/interfaceimplem.cpp
Normal file
6
src/CopyrighFixer/interfaceimplem.cpp
Normal file
@ -0,0 +1,6 @@
|
||||
#include "interfaceimplem.h"
|
||||
|
||||
InterfaceImplem::InterfaceImplem()
|
||||
{
|
||||
|
||||
}
|
11
src/CopyrighFixer/interfaceimplem.h
Normal file
11
src/CopyrighFixer/interfaceimplem.h
Normal file
@ -0,0 +1,11 @@
|
||||
#ifndef INTERFACEIMPLEM_H
|
||||
#define INTERFACEIMPLEM_H
|
||||
|
||||
|
||||
class InterfaceImplem
|
||||
{
|
||||
public:
|
||||
InterfaceImplem();
|
||||
};
|
||||
|
||||
#endif // INTERFACEIMPLEM_H
|
@ -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:
|
||||
|
33
tests/units/interfaceimplemtest.cpp
Normal file
33
tests/units/interfaceimplemtest.cpp
Normal 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();
|
||||
}
|
28
tests/units/interfaceimplemtest.h
Normal file
28
tests/units/interfaceimplemtest.h
Normal 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
|
Loading…
x
Reference in New Issue
Block a user