Skip to content
Snippets Groups Projects
Commit e0142f59 authored by Moritz Hanke's avatar Moritz Hanke
Browse files

improves test coverage of MPIOM reader

parent b6387cb3
No related branches found
No related tags found
No related merge requests found
......@@ -25,20 +25,33 @@ int main(int argc, char** argv) {
if (!yac_file_exists(grid_filename)) return EXIT_SKIP_TEST;
struct yac_basic_grid_data mpiom_grid =
yac_read_mpiom_basic_grid_data(grid_filename);
{
struct yac_basic_grid_data mpiom_grid =
yac_read_mpiom_basic_grid_data(grid_filename);
free(grid_filename);
if (mpiom_grid.num_cells != 12120)
PUT_ERR("wrong number of grid cells");
if (mpiom_grid.num_cells != 12120)
PUT_ERR("wrong number of grid cells");
// #define WRITE_VTK_GRID_FILE
#ifdef WRITE_VTK_GRID_FILE
yac_write_basic_grid_data_to_file(&mpiom_grid, "mpiom");
yac_write_basic_grid_data_to_file(&mpiom_grid, "mpiom");
#endif // WRITE_VTK_GRID_FILE
yac_basic_grid_data_free(mpiom_grid);
yac_basic_grid_data_free(mpiom_grid);
}
{
struct yac_basic_grid * mpiom_grid =
yac_read_mpiom_basic_grid(grid_filename, "mpiom");
if (yac_basic_grid_get_data_size(mpiom_grid, YAC_LOC_CELL) != 12120)
PUT_ERR("wrong number of grid cells");
yac_basic_grid_delete(mpiom_grid);
}
free(grid_filename);
return TEST_EXIT_CODE;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment