first version upgrade
[devspec.git] / devspec.en_US / project / recutils / torture / rec-fex / rec-fex-destroy.c
blob195329a9a75c393c0df93f112a94537ad2425c1c
1 /* -*- mode: C -*-
3 * File: rec-fex-destroy.c
4 * Date: Tue Nov 9 15:54:08 2010
6 * GNU recutils - rec_fex_destroy unit tests.
8 */
10 /* Copyright (C) 2010-2015 Jose E. Marchesi */
12 /* This program is free software: you can redistribute it and/or modify
13 * it under the terms of the GNU General Public License as published by
14 * the Free Software Foundation, either version 3 of the License, or
15 * (at your option) any later version.
17 * This program is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 * GNU General Public License for more details.
22 * You should have received a copy of the GNU General Public License
23 * along with this program. If not, see <http://www.gnu.org/licenses/>.
26 #include <config.h>
27 #include <string.h>
28 #include <check.h>
30 #include <rec.h>
32 /*-
33 * Test: rec_fex_destroy_nominal
34 * Unit: rec_fex_destroy
35 * Description:
36 * + Destroy a properly initialized field expression.
38 START_TEST(rec_fex_destroy_nominal)
40 rec_fex_t fex;
42 fex = rec_fex_new ("foo", REC_FEX_SIMPLE);
43 fail_if (fex == NULL);
45 rec_fex_destroy (fex);
47 END_TEST
50 * Test case creation function
52 TCase *
53 test_rec_fex_destroy (void)
55 TCase *tc = tcase_create ("rec_fex_new");
56 tcase_add_test (tc, rec_fex_destroy_nominal);
58 return tc;
61 /* End of rec-fex-destroy.c */