cmake/Source/cmTestGenerator.h

48 lines
1.3 KiB
C
Raw Normal View History

2016-10-30 18:24:19 +01:00
/* Distributed under the OSI-approved BSD 3-Clause License. See accompanying
file Copyright.txt or https://cmake.org/licensing for details. */
2009-10-04 10:30:41 +03:00
#ifndef cmTestGenerator_h
#define cmTestGenerator_h
2017-07-20 19:35:53 +02:00
#include "cmConfigure.h"
2016-10-30 18:24:19 +01:00
2009-10-04 10:30:41 +03:00
#include "cmScriptGenerator.h"
2016-10-30 18:24:19 +01:00
#include <iosfwd>
#include <string>
#include <vector>
2015-11-17 17:22:37 +01:00
class cmLocalGenerator;
2016-10-30 18:24:19 +01:00
class cmTest;
2009-10-04 10:30:41 +03:00
/** \class cmTestGenerator
* \brief Support class for generating install scripts.
*
*/
2016-07-09 11:21:54 +02:00
class cmTestGenerator : public cmScriptGenerator
2009-10-04 10:30:41 +03:00
{
2017-07-20 19:35:53 +02:00
CM_DISABLE_COPY(cmTestGenerator)
2009-10-04 10:30:41 +03:00
public:
cmTestGenerator(cmTest* test,
2016-07-09 11:21:54 +02:00
std::vector<std::string> const& configurations =
std::vector<std::string>());
2016-10-30 18:24:19 +01:00
~cmTestGenerator() CM_OVERRIDE;
2009-10-04 10:30:41 +03:00
2015-11-17 17:22:37 +01:00
void Compute(cmLocalGenerator* lg);
2009-10-04 10:30:41 +03:00
protected:
2017-07-20 19:35:53 +02:00
void GenerateScriptConfigs(std::ostream& os, Indent indent) CM_OVERRIDE;
void GenerateScriptActions(std::ostream& os, Indent indent) CM_OVERRIDE;
2016-10-30 18:24:19 +01:00
void GenerateScriptForConfig(std::ostream& os, const std::string& config,
2017-07-20 19:35:53 +02:00
Indent indent) CM_OVERRIDE;
void GenerateScriptNoConfig(std::ostream& os, Indent indent) CM_OVERRIDE;
2016-10-30 18:24:19 +01:00
bool NeedsScriptNoConfig() const CM_OVERRIDE;
2017-07-20 19:35:53 +02:00
void GenerateOldStyle(std::ostream& os, Indent indent);
2009-10-04 10:30:41 +03:00
2015-11-17 17:22:37 +01:00
cmLocalGenerator* LG;
2009-10-04 10:30:41 +03:00
cmTest* Test;
bool TestGenerated;
};
#endif