From cebe1906c3f42f093c497118d1048057ab4aec3a Mon Sep 17 00:00:00 2001 From: nyamatongwe Date: Tue, 1 Feb 2011 15:08:37 +1100 Subject: Unit tests for Scintilla data structures. --- test/unit/unitTest.cxx | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 test/unit/unitTest.cxx (limited to 'test/unit/unitTest.cxx') diff --git a/test/unit/unitTest.cxx b/test/unit/unitTest.cxx new file mode 100644 index 000000000..e1bb7bad2 --- /dev/null +++ b/test/unit/unitTest.cxx @@ -0,0 +1,50 @@ +// Unit Tests for Scintilla internal data structures + +/* + Currently tested: + SplitVector + Partitioning + ContractionState + + To do: + RunStyles + Decoration + DecorationList + PerLine * + CellBuffer * + Range + StyledText + CaseFolder ... + Document + RESearch + Selection + UniConversion + Style + + lexlib: + Accessor + LexAccessor + CharacterSet + OptionSet + PropSetSimple + StyleContext + WordList +*/ + +#include + +#include "Platform.h" + +#include + +// Needed for PLATFORM_ASSERT in code being tested + +void Platform::Assert(const char *c, const char *file, int line) { + fprintf(stderr, "Assertion [%s] failed at %s %d\n", c, file, line); + abort(); +} + +int main(int argc, char **argv) { + testing::InitGoogleTest(&argc, argv); + return RUN_ALL_TESTS(); +} -- cgit v1.2.3