X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Flanguage%2Ftests%2Fcasefile-test.c;h=eb8ee061956db8569e5c930d82157907ecf77ee4;hb=661b9ee29cbb6b89c4ea53a05b8a4eb3a5028de0;hp=0bafe5ef13aceb08c38537018afd3463f7788cf0;hpb=3816248a008a4af75aac6319d0c9929cb7ff679e;p=pspp-builds.git diff --git a/src/language/tests/casefile-test.c b/src/language/tests/casefile-test.c index 0bafe5ef..eb8ee061 100644 --- a/src/language/tests/casefile-test.c +++ b/src/language/tests/casefile-test.c @@ -1,6 +1,5 @@ /* PSPP - computes sample statistics. Copyright (C) 2004 Free Software Foundation, Inc. - Written by Ben Pfaff . This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as @@ -160,8 +159,8 @@ test_casefile (int pattern, size_t value_cnt, size_t case_cnt) fail_test ("Premature end of casefile."); for (j = 0; j < value_cnt; j++) { - double a = case_num (&read_case, j); - double b = case_num (&expected_case, j); + double a = case_num_idx (&read_case, j); + double b = case_num_idx (&expected_case, j); if (a != b) fail_test ("Case %lu fails comparison.", (unsigned long) i); } @@ -180,7 +179,7 @@ get_random_case (struct ccase *c, size_t value_cnt, size_t case_idx) int i; case_create (c, value_cnt); for (i = 0; i < value_cnt; i++) - case_data_rw (c, i)->f = case_idx % 257 + i; + case_data_rw_idx (c, i)->f = case_idx % 257 + i; } static void @@ -205,8 +204,8 @@ read_and_verify_random_case (struct casefile *cf, fail_test ("Premature end of casefile."); for (i = 0; i < value_cnt; i++) { - double a = case_num (&read_case, i); - double b = case_num (&expected_case, i); + double a = case_num_idx (&read_case, i); + double b = case_num_idx (&expected_case, i); if (a != b) fail_test ("Case %lu fails comparison.", (unsigned long) case_idx); }