Generator: added empty array test

This commit is contained in:
Benoît Blanchon
2014-06-24 13:19:23 +02:00
parent 3d8b31b1ec
commit c8c1add4ab
7 changed files with 200 additions and 0 deletions

View File

@ -0,0 +1,22 @@
#include "CppUnitTest.h"
#include "JsonArray.h"
using namespace Microsoft::VisualStudio::CppUnitTestFramework;
namespace JsonGeneratorTests
{
TEST_CLASS(JsonArrayTests)
{
public:
TEST_METHOD(EmptyArray)
{
JsonArray arr;
char buffer[256];
arr.writeTo(buffer, sizeof(buffer));
Assert::AreEqual("[]", buffer);
}
};
}