aboutsummaryrefslogtreecommitdiff
path: root/src/tests
diff options
context:
space:
mode:
authorMike Buland <eichlan@xagasoft.com>2010-08-14 07:12:29 +0000
committerMike Buland <eichlan@xagasoft.com>2010-08-14 07:12:29 +0000
commit1b797548dff7e2475826ba29a71c3f496008988f (patch)
tree2a81ee2e8fa2f17fd95410aabbf44533d35a727a /src/tests
downloadlibgats-1b797548dff7e2475826ba29a71c3f496008988f.tar.gz
libgats-1b797548dff7e2475826ba29a71c3f496008988f.tar.bz2
libgats-1b797548dff7e2475826ba29a71c3f496008988f.tar.xz
libgats-1b797548dff7e2475826ba29a71c3f496008988f.zip
libgats gets it's own repo. The rest of the history is in my misc repo.
Diffstat (limited to 'src/tests')
-rw-r--r--src/tests/int.cpp21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/tests/int.cpp b/src/tests/int.cpp
new file mode 100644
index 0000000..5d5b7d2
--- /dev/null
+++ b/src/tests/int.cpp
@@ -0,0 +1,21 @@
1#include "gats/integer.h"
2
3#include <bu/sio.h>
4#include <bu/membuf.h>
5
6using namespace Bu;
7
8int main()
9{
10 MemBuf mb;
11 int64_t i = -53954321995838ll;
12
13 sio << "Before: " << i << sio.nl;
14 Gats::Integer::writePackedInt( mb, i );
15 mb.setPos( 0 );
16 Gats::Integer::readPackedInt( mb, i );
17 sio << "After: " << i << sio.nl;
18
19 return 0;
20}
21