aboutsummaryrefslogtreecommitdiff
path: root/src/tests
diff options
context:
space:
mode:
authorMike Buland <eichlan@xagasoft.com>2009-02-10 22:26:46 +0000
committerMike Buland <eichlan@xagasoft.com>2009-02-10 22:26:46 +0000
commit292ae9453e7fdb2f1023ed9dfc99cbcd751f8b90 (patch)
treee7cdb8620f4a16f114058dd245b51a8858eacbb1 /src/tests
parent1a0f10f17a85afef20a2610104d590fb1e41cffa (diff)
downloadlibbu++-292ae9453e7fdb2f1023ed9dfc99cbcd751f8b90.tar.gz
libbu++-292ae9453e7fdb2f1023ed9dfc99cbcd751f8b90.tar.bz2
libbu++-292ae9453e7fdb2f1023ed9dfc99cbcd751f8b90.tar.xz
libbu++-292ae9453e7fdb2f1023ed9dfc99cbcd751f8b90.zip
Hey, got the formatter working, that's something. I really like it so far,
lets see how nice we can really make it.
Diffstat (limited to 'src/tests')
-rw-r--r--src/tests/stdstream.cpp21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/tests/stdstream.cpp b/src/tests/stdstream.cpp
new file mode 100644
index 0000000..d67f9b8
--- /dev/null
+++ b/src/tests/stdstream.cpp
@@ -0,0 +1,21 @@
1#include "bu/sio.h"
2
3int main()
4{
5 Bu::sio << "Hello there" << Bu::sio.nl;
6
7 Bu::sio << "sizeof(Fmt) = " << sizeof(Bu::Fmt) << Bu::sio.nl;
8
9 Bu::sio << -123 << ", " << 0 << ", " << 123 << Bu::sio.nl;
10
11 Bu::sio << "+----------+" << Bu::sio.nl;
12 Bu::sio << "|" << Bu::Fmt( 10, 10, Bu::Fmt::Center ) << "Test" << "|" << Bu::sio.nl;
13 Bu::sio << "+----------+" << Bu::sio.nl;
14 Bu::sio << "|" << Bu::Fmt( 10, 10, Bu::Fmt::Left ) << 123 << "|" << Bu::sio.nl;
15 Bu::sio << "|" << Bu::Fmt( 10, 10, Bu::Fmt::Center ) << 123 << "|" << Bu::sio.nl;
16 Bu::sio << "|" << Bu::Fmt( 10, 10, Bu::Fmt::Right ) << 123 << "|" << Bu::sio.nl;
17 Bu::sio << "+----------+" << Bu::sio.nl;
18
19 return 0;
20}
21