aboutsummaryrefslogtreecommitdiff
path: root/test/090_tables_readwrite
diff options
context:
space:
mode:
Diffstat (limited to 'test/090_tables_readwrite')
-rw-r--r--test/090_tables_readwrite/00_table.in1
-rw-r--r--test/090_tables_readwrite/00_table.out1
-rw-r--r--test/090_tables_readwrite/tables_readwrite_tests.c5
3 files changed, 6 insertions, 1 deletions
diff --git a/test/090_tables_readwrite/00_table.in b/test/090_tables_readwrite/00_table.in
index f286968..579736a 100644
--- a/test/090_tables_readwrite/00_table.in
+++ b/test/090_tables_readwrite/00_table.in
@@ -5,6 +5,7 @@ Test solver
5100000000000 5100000000000
612345678912345 612345678912345
7399999999998 7399999999998
83393
82 92
90 100
1020 1120
diff --git a/test/090_tables_readwrite/00_table.out b/test/090_tables_readwrite/00_table.out
index f286968..579736a 100644
--- a/test/090_tables_readwrite/00_table.out
+++ b/test/090_tables_readwrite/00_table.out
@@ -5,6 +5,7 @@ Test solver
5100000000000 5100000000000
612345678912345 612345678912345
7399999999998 7399999999998
83393
82 92
90 100
1020 1120
diff --git a/test/090_tables_readwrite/tables_readwrite_tests.c b/test/090_tables_readwrite/tables_readwrite_tests.c
index f3162ea..32d171a 100644
--- a/test/090_tables_readwrite/tables_readwrite_tests.c
+++ b/test/090_tables_readwrite/tables_readwrite_tests.c
@@ -1,7 +1,7 @@
1#include "../test.h" 1#include "../test.h"
2 2
3#define INFOSIZE 512 3#define INFOSIZE 512
4#define INFO_SOLVER_STRLEN 20 4#define INFO_SOLVER_STRLEN 100
5#define INFO_DISTRIBUTION_LEN 21 5#define INFO_DISTRIBUTION_LEN 21
6 6
7typedef struct { 7typedef struct {
@@ -11,6 +11,7 @@ typedef struct {
11 uint64_t fullsize; 11 uint64_t fullsize;
12 uint64_t hash; 12 uint64_t hash;
13 uint64_t entries; 13 uint64_t entries;
14 uint64_t classes;
14 uint8_t bits; 15 uint8_t bits;
15 uint8_t base; 16 uint8_t base;
16 uint8_t maxvalue; 17 uint8_t maxvalue;
@@ -45,6 +46,7 @@ tableinfo_t test_readinfo(void) {
45 ret.fullsize = readn(); 46 ret.fullsize = readn();
46 ret.hash = readn(); 47 ret.hash = readn();
47 ret.entries = readn(); 48 ret.entries = readn();
49 ret.classes = readn();
48 ret.bits = (uint8_t)readn(); 50 ret.bits = (uint8_t)readn();
49 ret.base = (uint8_t)readn(); 51 ret.base = (uint8_t)readn();
50 ret.maxvalue = (uint8_t)readn(); 52 ret.maxvalue = (uint8_t)readn();
@@ -69,6 +71,7 @@ void test_writeinfo(tableinfo_t info) {
69 printf("%" PRIu64 "\n", info.fullsize); 71 printf("%" PRIu64 "\n", info.fullsize);
70 printf("%" PRIu64 "\n", info.hash); 72 printf("%" PRIu64 "\n", info.hash);
71 printf("%" PRIu64 "\n", info.entries); 73 printf("%" PRIu64 "\n", info.entries);
74 printf("%" PRIu64 "\n", info.classes);
72 printf("%" PRIu8 "\n", info.bits); 75 printf("%" PRIu8 "\n", info.bits);
73 printf("%" PRIu8 "\n", info.base); 76 printf("%" PRIu8 "\n", info.base);
74 printf("%" PRIu8 "\n", info.maxvalue); 77 printf("%" PRIu8 "\n", info.maxvalue);

Generated with cgit - Back to sebastiano.tronto.net