From ca7d122b7b3fb57d6cabdbdc5da9c1ecc60de5d8 Mon Sep 17 00:00:00 2001 From: hunt Date: Tue, 17 May 2005 06:58:05 +0000 Subject: Restructuring of tests. New tests for new maps. --- runtime/tests/testl64R.c | 50 ------------------------------------------------ 1 file changed, 50 deletions(-) delete mode 100644 runtime/tests/testl64R.c (limited to 'runtime/tests/testl64R.c') diff --git a/runtime/tests/testl64R.c b/runtime/tests/testl64R.c deleted file mode 100644 index b5db7228..00000000 --- a/runtime/tests/testl64R.c +++ /dev/null @@ -1,50 +0,0 @@ -#include "test.h" - -#define LLONG_MAX 9223372036854775807LL -#define LLONG_MIN (-LLONG_MAX - 1LL) - -/* testl64R.c - DO NOT EDIT without updating the expected results in map.test. */ - -/* - key - long - val - INT64 - - Testing range of values -*/ - -int main () -{ - struct map_node_int64 *ptr; - MAP mymap = map_new(4, INT64); - - map_key_long (mymap, 1); - map_set_int64 (mymap, LLONG_MIN); - map_key_long (mymap, 2); - map_set_int64 (mymap, LLONG_MAX); - map_key_long (mymap, 3); - map_set_int64 (mymap, 0); /* will not be saved */ - map_key_long (mymap, 4); - map_set_int64 (mymap, -1); - map_key_long (mymap, 5); - map_set_int64 (mymap, 5); - - - for (ptr = (struct map_node_int64 *)map_start(mymap); ptr; - ptr = (struct map_node_int64 *)map_iter (mymap, (struct map_node *)ptr)) - printf ("mymap[%ld] = %lld\n", key1int(ptr), (long long)ptr->val); - - - /* stress test - create a million entries then print last 4 */ - int i; - for (i = 0; i < 1000000; i++) - { - map_key_long (mymap, i); - map_set_int64 (mymap, i+i); - } - - for (ptr = (struct map_node_int64 *)map_start(mymap); ptr; - ptr = (struct map_node_int64 *)map_iter (mymap, (struct map_node *)ptr)) - printf ("mymap[%ld] = %lld\n", key1int(ptr), (long long)ptr->val); - - return 0; -} -- cgit