aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Buland <eichlan@xagasoft.com>2011-07-13 01:44:46 +0000
committerMike Buland <eichlan@xagasoft.com>2011-07-13 01:44:46 +0000
commit0bc7562c218376b44a3eb87db0e310df0b1d0036 (patch)
tree1538aa05af5fd0ef1ff6e3baedbdd46c6f5a4822
parent6db5a815fef8c5372220cc223b1a8edcb99f3744 (diff)
downloadlibbu++-0bc7562c218376b44a3eb87db0e310df0b1d0036.tar.gz
libbu++-0bc7562c218376b44a3eb87db0e310df0b1d0036.tar.bz2
libbu++-0bc7562c218376b44a3eb87db0e310df0b1d0036.tar.xz
libbu++-0bc7562c218376b44a3eb87db0e310df0b1d0036.zip
Trying to hunt down bug in variant code.
-rw-r--r--src/unit/variant.unit13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/unit/variant.unit b/src/unit/variant.unit
index ca977ee..1654c4f 100644
--- a/src/unit/variant.unit
+++ b/src/unit/variant.unit
@@ -7,6 +7,9 @@
7 */ 7 */
8 8
9#include "bu/variant.h" 9#include "bu/variant.h"
10#include "bu/membuf.h"
11#include "bu/formatter.h"
12#include "bu/string.h"
10 13
11suite Variant 14suite Variant
12{ 15{
@@ -18,4 +21,14 @@ suite Variant
18 Bu::Variant v2( v ); 21 Bu::Variant v2( v );
19 v2.get<int>(); 22 v2.get<int>();
20 } 23 }
24
25 test formatting
26 {
27 Bu::Variant v("hello");
28 Bu::MemBuf mb;
29 Bu::Formatter f( mb );
30 f << v;
31 unitTest( mb.getString() == v.get<Bu::String>() );
32
33 }
21} 34}