CvrStgFileTest.h
Go to the documentation of this file.
/*
* steghide 0.5.1 - a steganography program
* Copyright (C) 1999-2003 Stefan Hetzl <shetzl@chello.at>
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*
*/
#ifndef SH_CVRSTGFILETEST_H
#define SH_CVRSTGFILETEST_H
#include "BitString.h"
#include "CvrStgFile.h"
#include "UnitTest.h"
#include "TestSuite.h"
class CvrStgFileTest : public UnitTest {
public:
CvrStgFileTest (std::string n, TestSuite* s) : UnitTest(n,s) {} ;
protected:
bool genericTestReadWrite (const std::string& rfn, bool new_wfn = true) const ;
bool genericTestReadEmbedExtract (const std::string& fn, BitString& emb) const ;
bool genericTestReadExtractCompare (const std::string& fn, BitString& emb) const ;
bool genericTestReadEmbedWriteReadExtract (const std::string& cvrfn, BitString& emb) const ;
bool genericTestPosition (const CvrStgFile* f, const SamplePos pos, SampleValue* sv_r) const ;
bool genericTestSVALCalculation (const CvrStgFile* f, const Graph* g) const ;
bool genericTestEmbeddedValue (const CvrStgFile* f) const ;
private:
bool areEqual (const std::string& fn1, const std::string& fn2) const ;
void removeFile (const std::string& fn) const ;
void copyFile (const std::string& src, const std::string& dest) const ;
void moveFile (const std::string& src, const std::string& dest) const ;
} ;
#endif // ndef SH_CVRSTGFILETEST_H
CvrStgFileTest::areEqual
bool areEqual(const std::string &fn1, const std::string &fn2) const
Definition: CvrStgFileTest.cc:182
CvrStgFileTest::genericTestSVALCalculation
bool genericTestSVALCalculation(const CvrStgFile *f, const Graph *g) const
Definition: CvrStgFileTest.cc:159
CvrStgFileTest::copyFile
void copyFile(const std::string &src, const std::string &dest) const
Definition: CvrStgFileTest.cc:196
Graph
a graph constructed from a cover file and a message to be embedded
Definition: Graph.h:51
CvrStgFile
a cover-/stego-file
Definition: CvrStgFile.h:46
CvrStgFileTest::genericTestReadExtractCompare
bool genericTestReadExtractCompare(const std::string &fn, BitString &emb) const
Definition: CvrStgFileTest.cc:61
CvrStgFileTest::genericTestReadWrite
bool genericTestReadWrite(const std::string &rfn, bool new_wfn=true) const
Definition: CvrStgFileTest.cc:34
SamplePos
UWORD32 SamplePos
Definition: common.h:67
CvrStgFileTest
Definition: CvrStgFileTest.h:30
BitString.h
CvrStgFileTest::genericTestReadEmbedWriteReadExtract
bool genericTestReadEmbedWriteReadExtract(const std::string &cvrfn, BitString &emb) const
Definition: CvrStgFileTest.cc:103
SampleValue
the value of a sample in a CvrStgFile
Definition: SampleValue.h:61
CvrStgFileTest::CvrStgFileTest
CvrStgFileTest(std::string n, TestSuite *s)
Definition: CvrStgFileTest.h:32
CvrStgFileTest::removeFile
void removeFile(const std::string &fn) const
Definition: CvrStgFileTest.cc:189
CvrStgFileTest::genericTestReadEmbedExtract
bool genericTestReadEmbedExtract(const std::string &fn, BitString &emb) const
Definition: CvrStgFileTest.cc:74
UnitTest
Definition: UnitTest.h:38
UnitTest.h
CvrStgFile.h
TestSuite
Definition: TestSuite.h:31
BitString
a string of bits
Definition: BitString.h:42
TestSuite.h
CvrStgFileTest::genericTestPosition
bool genericTestPosition(const CvrStgFile *f, const SamplePos pos, SampleValue *sv_r) const
Definition: CvrStgFileTest.cc:144
CvrStgFileTest::genericTestEmbeddedValue
bool genericTestEmbeddedValue(const CvrStgFile *f) const
Definition: CvrStgFileTest.cc:171
CvrStgFileTest::moveFile
void moveFile(const std::string &src, const std::string &dest) const
Definition: CvrStgFileTest.cc:203