Gromacs
5.1.2
|
#include <testutils/testfileredirector.h>
In-memory implementation for FileInputRedirectorInterface for tests.
By default, this implementation will return false
for all file existence checks. To return true
for a specific path, use addExistingFile().
Public Member Functions | |
void | addExistingFile (const char *filename) |
Marks the provided path as an existing file. More... | |
virtual bool | fileExists (const char *filename) const |
Checks whether the provided path exists (and is a file). | |
bool | fileExists (const std::string &filename) const |
Convenience method to check file existence using an std::string path. | |
void gmx::test::TestFileInputRedirector::addExistingFile | ( | const char * | filename | ) |
Marks the provided path as an existing file.
std::bad_alloc | if out of memory. |
Further checks for existence of the given path will return true
.