Skip to content

Commit

Permalink
Add NOT_USEDs
Browse files Browse the repository at this point in the history
  • Loading branch information
dpt committed Feb 22, 2024
1 parent de632de commit 98cbc14
Show file tree
Hide file tree
Showing 17 changed files with 39 additions and 3 deletions.
2 changes: 2 additions & 0 deletions libraries/databases/pickle/test/pickle-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -599,6 +599,8 @@ result_t pickle_test(const char *resources)
{
result_t rc;

NOT_USED(resources);

printf("test: pickle test 1\n");

rc = pickle__test1_write();
Expand Down
2 changes: 2 additions & 0 deletions libraries/databases/tag-db/test/tag-db-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -882,6 +882,8 @@ result_t tagdb_test(const char *resources)
State_t state;
int i;

NOT_USED(resources);

printf("test: init\n");

err = tagdb_init();
Expand Down
2 changes: 2 additions & 0 deletions libraries/datastruct/atom/test/atom-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,8 @@ result_t atom_test(const char *resources)
result_t err;
atom_set_t *d;

NOT_USED(resources);

d = atom_create_tuned(1, 12);
if (d == NULL)
goto Failure;
Expand Down
3 changes: 3 additions & 0 deletions libraries/datastruct/bitarr/test/bitarr-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
#endif

#include "base/result.h"
#include "base/utils.h"
#include "datastruct/bitarr.h"

#include "test/all-tests.h"
Expand Down Expand Up @@ -39,6 +40,8 @@ result_t bitarr_test(const char *resources)
testbits_t arr;
int i;

NOT_USED(resources);

printf("test: create\n");

bitarr_wipe(arr, sizeof(arr));
Expand Down
5 changes: 3 additions & 2 deletions libraries/datastruct/bitfifo/test/bitfifo-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
#endif

#include "base/result.h"
#include "base/utils.h"
#include "datastruct/bitfifo.h"

#include "test/all-tests.h"
Expand All @@ -30,8 +31,6 @@ expected[] =
{ 32, 0xFFFFFFFF },
};

#define NELEMS(a) (int)(sizeof(a) / sizeof((a)[0]))

/* shows changes from previous stats */
static void dump(const bitfifo_t *fifo)
{
Expand Down Expand Up @@ -70,6 +69,8 @@ result_t bitfifo_test(const char *resources)
int i;
unsigned int outbits;

NOT_USED(resources);

fifo = bitfifo_create(MAXSIZE);
if (fifo == NULL)
return result_OOM;
Expand Down
3 changes: 3 additions & 0 deletions libraries/datastruct/bitvec/test/bitvec-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
#endif

#include "base/result.h"
#include "base/utils.h"
#include "datastruct/bitvec.h"

#include "test/all-tests.h"
Expand All @@ -30,6 +31,8 @@ result_t bitvec_test(const char *resources)
bitvec_t *w;
bitvec_t *x;

NOT_USED(resources);

printf("test: create\n");

v = bitvec_create(0);
Expand Down
3 changes: 3 additions & 0 deletions libraries/datastruct/cache/test/cache-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
#endif

#include "base/result.h"
#include "base/utils.h"
#include "datastruct/cache.h"

#include "test/all-tests.h"
Expand All @@ -25,6 +26,8 @@ result_t cache_test(const char *resources)
int nfailures;
int i;

NOT_USED(resources);

config.hash_chain_length = 4;
config.nentries_percentage = 25;

Expand Down
2 changes: 2 additions & 0 deletions libraries/datastruct/hash/test/hash-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,8 @@ result_t hash_test(const char *resources)
hash_t *d;
int i;

NOT_USED(resources);

printf("test: create\n");

/* use default string handling */
Expand Down
2 changes: 2 additions & 0 deletions libraries/datastruct/list/test/list-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,8 @@ result_t list_test(const char *resources)

int i;

NOT_USED(resources);

printf("test: add to head\n");

for (i = 0; i < NELEMS(data); i++)
Expand Down
2 changes: 2 additions & 0 deletions libraries/datastruct/ntree/test/ntree-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,8 @@ result_t ntree_test(const char *resources)
int nfailures = 0;
int i;

NOT_USED(resources);

BEGIN_TEST("build tree");

for (i = 0; i < NELEMS(test_data); i++)
Expand Down
2 changes: 2 additions & 0 deletions libraries/datastruct/vector/test/vector-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ result_t vector_test(const char *resources)
int i;
int *p;

NOT_USED(resources);

printf("test: create\n");

v = vector_create(WIDTH);
Expand Down
2 changes: 2 additions & 0 deletions libraries/geom/box/test/box-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,8 @@ result_t box_test(const char *resources)
size_t i;
int nfailures;

NOT_USED(resources);

nfailures = 0;
for (i = 0; i < NELEMS(tests); i++)
{
Expand Down
2 changes: 2 additions & 0 deletions libraries/geom/layout/test/layout-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ result_t layout_test(const char *resources)
box_t used;
txtscr_t *scr;

NOT_USED(resources);

packer = packer_create(&dims);
if (packer == NULL)
goto failure;
Expand Down
2 changes: 2 additions & 0 deletions libraries/geom/packer/test/packer-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -403,6 +403,8 @@ result_t packer_test(const char *resources)
{
result_t err;

NOT_USED(resources);

err = test1();
if (err)
goto failure;
Expand Down
2 changes: 2 additions & 0 deletions libraries/io/stream/test/stream-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -287,6 +287,8 @@ result_t stream_test(const char *resources)
{
result_t rc;

NOT_USED(resources);

rc = test_getc_empty();
if (rc)
goto Failure;
Expand Down
2 changes: 2 additions & 0 deletions libraries/utils/array/test/array-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ result_t array_test(const char *resources)
int t;
int i;

NOT_USED(resources);


printf("test: delete element\n");

Expand Down
4 changes: 3 additions & 1 deletion libraries/utils/bsearch/test/bsearch-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,12 @@

result_t bsearch_test(const char *resources)
{
static const int ints[] = { INT_MIN, INT_MIN + 1, INT_MAX - 1, INT_MAX };

int i;
int nfailures = 0;

static const int ints[] = { INT_MIN, INT_MIN + 1, INT_MAX - 1, INT_MAX };
NOT_USED(resources);

printf("test: int array\n");

Expand Down

0 comments on commit 98cbc14

Please sign in to comment.