Skip to content

Commit

Permalink
Fix warnings in tests without xml support
Browse files Browse the repository at this point in the history
  • Loading branch information
elrnv committed Feb 17, 2023
1 parent ff8a5ab commit 9da2b34
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/pygmsh.rs
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,7 @@ fn legacy_binary() -> Result {

/// Ensures that points from the two given vtk files are equivalent up to floating point error, and then overwrites
/// the first input to match exactly to the points in the second input, so the can be compared using `PartialEq` later.
#[cfg(feature = "xml")]
fn compare_points_in_float_and_overwrite(vtu: &mut Vtk, expected: &Vtk) {
let expected_points = if let DataSet::UnstructuredGrid { ref pieces, .. } = expected.data {
pieces[0]
Expand Down Expand Up @@ -226,6 +227,7 @@ fn compare_points_in_float_and_overwrite(vtu: &mut Vtk, expected: &Vtk) {

/// Ensures the given xml based vtk file has the right values and overwrites them to match
/// the asset returned by make_test_file.
#[cfg(feature = "xml")]
fn assert_and_fix_xml_vtu(vtu: &mut Vtk) {
vtu.file_path = None; // Reset file path to satisfy comparison
assert_eq!(vtu.version, Version::new_xml(0, 1)); // XML file version is ignored.
Expand Down

0 comments on commit 9da2b34

Please sign in to comment.