aboutsummaryrefslogtreecommitdiff
path: root/src/unit
diff options
context:
space:
mode:
authorMike Buland <eichlan@xagasoft.com>2019-08-08 09:59:52 -0700
committerMike Buland <eichlan@xagasoft.com>2019-08-08 09:59:52 -0700
commit238244337283a7f888cf49a1e56b809c22466a63 (patch)
tree5262c5bfed957edc0906c002e0e94bbc88154d08 /src/unit
parentaf4bc8816eb4b4cb4821b24706f55b518a43968d (diff)
downloadlibbu++-238244337283a7f888cf49a1e56b809c22466a63.tar.gz
libbu++-238244337283a7f888cf49a1e56b809c22466a63.tar.bz2
libbu++-238244337283a7f888cf49a1e56b809c22466a63.tar.xz
libbu++-238244337283a7f888cf49a1e56b809c22466a63.zip
Fixed a bug in the BlobBuilder.
Appending wasn't working correctly.
Diffstat (limited to '')
-rw-r--r--src/unit/blobbuilder.unit13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/unit/blobbuilder.unit b/src/unit/blobbuilder.unit
index 84bf549..7f3fb93 100644
--- a/src/unit/blobbuilder.unit
+++ b/src/unit/blobbuilder.unit
@@ -17,6 +17,7 @@ suite BlobBuilder
17{ 17{
18 test append 18 test append
19 { 19 {
20 /*
20 Bu::BlobBuilder a; 21 Bu::BlobBuilder a;
21 a.append("a"); 22 a.append("a");
22 a.append("bc"); 23 a.append("bc");
@@ -24,5 +25,17 @@ suite BlobBuilder
24 Bu::println(">%1<\n\n").arg( a.getBlob() ); 25 Bu::println(">%1<\n\n").arg( a.getBlob() );
25 a.append("abcdef"); 26 a.append("abcdef");
26 Bu::println(">%1<\n\n").arg( a.getBlob() ); 27 Bu::println(">%1<\n\n").arg( a.getBlob() );
28 */
29 }
30
31 test appendChar
32 {
33 Bu::BlobBuilder a;
34 for( int j = 0; j < 20; j++ )
35 {
36 a += 'A';
37 }
38 Bu::println("%1").arg( a.getBlob() );
39 unitTest( a.getBlob() == "AAAAAAAAAAAAAAAAAAAA" );
27 } 40 }
28} 41}