da378efaaa
written some tests based on a non-working feature (operator[] = operator[])
Kjistóf2016-11-02 10:59:41 +01:00
bdfc14357a
made some final changes to the comments
Kjistóf2016-10-29 20:08:55 +02:00
f284a9a471
added noexcept qualifier to Char ctor, and made notes on exception safety
Kjistóf2016-10-29 13:37:03 +02:00
2e05bcb2e6
added some comments to CMakeLists.txt
Kjistóf2016-10-29 11:47:39 +02:00
6d1245bf0b
made some clarifications in one of the comments in class String
Kjistóf2016-10-29 11:42:58 +02:00
de6273cc63
added a comment to class Char
Kjistóf2016-10-29 11:39:18 +02:00
69d51127a0
CMakeLists.txt now uses manualtest.cpp if Google Test was not found
Kjistóf2016-10-28 20:25:43 +02:00
4ed53c1484
fixed a bug in manualtest.cpp, where a method was defined instead of default ctor
Kjistóf2016-10-28 20:24:57 +02:00
5711cb6096
refactored code, made new comments, extended manualtest.cpp, commented out tests of unimplemented stuff in test.cpp
Kjistóf2016-10-26 16:37:18 +02:00
c1254caf25
fixed a bug, where Char::operator= made the allocated data larger than needed
Kjistóf2016-10-25 15:38:32 +02:00
af27d29d29
fixed a bug in String::operator+ and String::operator+=
Kjistóf2016-10-25 15:05:40 +02:00
b74a35d1ec
added noexcept qualifiers where needed
Kjistóf2016-10-25 14:22:50 +02:00
8ef6635b9d
rewritten manualtest.cpp to be nicer and more readable
Kjistóf2016-10-24 22:11:57 +02:00
b9485acce8
added a comment to test.cpp
Kjistóf2016-10-24 21:34:52 +02:00
af4fede463
made some more tests parametric & made some cosmetic changes to the tests
Kjistóf2016-10-24 21:26:45 +02:00
3149e1a653
rewritten some of the parametric test cases to use std::string
Kjistóf2016-10-24 21:08:01 +02:00
a9307e5657
added pthread to CMakeLists.txt, it seems like it's needed on linux
Kjistóf2016-10-24 00:10:53 +02:00
0bf31cb6e4
made another test parametric, started to struggle with segfaults.
Kjistóf2016-10-23 23:48:20 +02:00
80f0c71445
made test.cpp format more reasonable
Kjistóf2016-10-23 22:17:30 +02:00
d5e355bf0b
written some parametric tests, few more to go
Kjistóf2016-10-23 21:05:14 +02:00
06cebc829e
made Char ctor explicit
Kjistóf2016-10-23 18:00:22 +02:00
bc0fc06772
added some comments for class Char, and added some TODO's
Kjistóf2016-10-23 15:41:32 +02:00
53efe34ed1
added manual test for new Char copy-on-write mechanic
Kjistóf2016-10-23 15:30:25 +02:00
4a1709d626
now the non-const String::operator[] returns a Char class instead of a primitive
Kjistóf2016-10-23 15:29:06 +02:00
44ef56941e
made an index_of() method for StringValue, which calculates the index of a char
Kjistóf2016-10-23 15:28:28 +02:00
8dcfca2d62
made a char wrapper: Char, which implements copy-on-write for String
Kjistóf2016-10-23 15:27:00 +02:00
cd7d35da9a
added some new, forgotten test cases and made some new ones for the new methods of String
Kjistóf2016-10-23 14:14:41 +02:00
c42cd20dd6
added new manual tests for new methods in String
Kjistóf2016-10-23 14:14:14 +02:00
1dec4febcc
implemented remaining methods and added checks to neccessary methods (some methods, like size() could segfault on empty Strings)
Kjistóf2016-10-23 14:12:56 +02:00
06d045f457
fixed overflow detection in StringValue::operator[]
Kjistóf2016-10-23 14:12:13 +02:00
c3f6968411
added a "manual" test, so the code can be profiled / leak checked in valgrind
Kjistóf2016-10-23 03:47:16 +02:00
48dd293d1d
added unit tests using GTest library
Kjistóf2016-10-23 03:46:48 +02:00
36dc44ac2d
added implementations for every header
Kjistóf2016-10-23 03:46:28 +02:00
9311aa6938
added header files for String and StringValue
Kjistóf2016-10-23 03:45:46 +02:00