2009-07-29 22:27:20 +00:00
|
|
|
#ifndef TESTS_H_62B23520_7C8E_11DE_8A39_0800200C9A66
|
|
|
|
|
#define TESTS_H_62B23520_7C8E_11DE_8A39_0800200C9A66
|
|
|
|
|
|
2011-09-06 00:16:03 -05:00
|
|
|
#if defined(_MSC_VER) || (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4
|
2011-03-02 06:11:41 +00:00
|
|
|
#pragma once
|
|
|
|
|
#endif
|
|
|
|
|
|
2008-09-03 22:20:39 +00:00
|
|
|
#include <string>
|
|
|
|
|
|
|
|
|
|
namespace Test {
|
2009-05-31 06:36:01 +00:00
|
|
|
void RunAll();
|
|
|
|
|
|
|
|
|
|
namespace Parser {
|
|
|
|
|
// scalar tests
|
|
|
|
|
void SimpleScalar(std::string& inputScalar, std::string& desiredOutput);
|
|
|
|
|
void MultiLineScalar(std::string& inputScalar, std::string& desiredOutput);
|
|
|
|
|
void LiteralScalar(std::string& inputScalar, std::string& desiredOutput);
|
|
|
|
|
void FoldedScalar(std::string& inputScalar, std::string& desiredOutput);
|
|
|
|
|
void ChompedFoldedScalar(std::string& inputScalar, std::string& desiredOutput);
|
|
|
|
|
void ChompedLiteralScalar(std::string& inputScalar, std::string& desiredOutput);
|
|
|
|
|
void FoldedScalarWithIndent(std::string& inputScalar, std::string& desiredOutput);
|
|
|
|
|
void ColonScalar(std::string& inputScalar, std::string& desiredOutput);
|
|
|
|
|
void QuotedScalar(std::string& inputScalar, std::string& desiredOutput);
|
|
|
|
|
void CommaScalar(std::string& inputScalar, std::string& desiredOutput);
|
|
|
|
|
void DashScalar(std::string& inputScalar, std::string& desiredOutput);
|
|
|
|
|
void URLScalar(std::string& inputScalar, std::string& desiredOutput);
|
|
|
|
|
|
|
|
|
|
// misc tests
|
|
|
|
|
bool SimpleSeq();
|
|
|
|
|
bool SimpleMap();
|
|
|
|
|
bool FlowSeq();
|
|
|
|
|
bool FlowMap();
|
2009-09-02 21:39:57 +00:00
|
|
|
bool FlowMapWithOmittedKey();
|
|
|
|
|
bool FlowMapWithOmittedValue();
|
2009-09-05 22:42:01 +00:00
|
|
|
bool FlowMapWithSoloEntry();
|
|
|
|
|
bool FlowMapEndingWithSoloEntry();
|
2009-07-25 18:58:41 +00:00
|
|
|
bool QuotedSimpleKeys();
|
2009-08-24 22:56:54 +00:00
|
|
|
bool CompressedMapAndSeq();
|
2009-07-30 06:49:09 +00:00
|
|
|
bool NullBlockSeqEntry();
|
|
|
|
|
bool NullBlockMapKey();
|
|
|
|
|
bool NullBlockMapValue();
|
2009-08-24 22:56:54 +00:00
|
|
|
bool SimpleAlias();
|
|
|
|
|
bool AliasWithNull();
|
2009-09-05 03:49:38 +00:00
|
|
|
bool AnchorInSimpleKey();
|
|
|
|
|
bool AliasAsSimpleKey();
|
2009-08-26 16:15:27 +00:00
|
|
|
bool ExplicitDoc();
|
|
|
|
|
bool MultipleDocs();
|
2009-08-26 16:23:58 +00:00
|
|
|
bool ExplicitEndDoc();
|
|
|
|
|
bool MultipleDocsWithSomeExplicitIndicators();
|
2009-05-31 06:36:01 +00:00
|
|
|
}
|
2008-09-03 22:20:39 +00:00
|
|
|
}
|
2009-07-29 22:27:20 +00:00
|
|
|
|
|
|
|
|
#endif // TESTS_H_62B23520_7C8E_11DE_8A39_0800200C9A66
|