Added test cases for OnDiskBlob that load and compare data
This commit is contained in:
parent
47a35c94b4
commit
2d45783414
@ -23,7 +23,7 @@ void VirtualTestFile::fillFileWithRandomData(long long int IV) {
|
||||
}
|
||||
}
|
||||
|
||||
const char *VirtualTestFile::data() {
|
||||
const char *VirtualTestFile::data() const {
|
||||
return _fileData;
|
||||
}
|
||||
|
||||
@ -33,7 +33,7 @@ int VirtualTestFile::read(void *buf, size_t count, off_t offset) {
|
||||
return realCount;
|
||||
}
|
||||
|
||||
size_t VirtualTestFile::size() {
|
||||
size_t VirtualTestFile::size() const {
|
||||
return _size;
|
||||
}
|
||||
|
||||
|
@ -14,9 +14,9 @@ public:
|
||||
// Return true, iff the given data is equal to the data of the file at the given offset.
|
||||
bool fileContentEqual(const char *content, size_t count, off_t offset);
|
||||
|
||||
const char *data();
|
||||
const char *data() const;
|
||||
|
||||
size_t size();
|
||||
size_t size() const;
|
||||
|
||||
protected:
|
||||
char *_fileData;
|
||||
|
Loading…
x
Reference in New Issue
Block a user