Skip to content

Commit

Permalink
abcd
Browse files Browse the repository at this point in the history
  • Loading branch information
jyoo1042 committed Dec 6, 2023
1 parent 03e1603 commit ff4e818
Showing 1 changed file with 8 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -171,18 +171,16 @@ void test_variables(const DataType& used_for_size) {
{"rest_mass_density", "spatial_velocity", "specific_internal_energy",
"pressure", "lorentz_factor", "specific_enthalpy"},
{{{-20., 20.}}}, member_variables, used_for_size, 1.0e-8);
const auto magnetic_field =
get<hydro::Tags::SpatialVelocity<DataType, 3>>(another_disk.variables(
coords, tmpl::list<hydro::Tags::SpatialVelocity<DataType, 3>>{}));
const auto [magnetic_field, div_clean_field] =
another_disk.variables(
coords, tmpl::list<hydro::Tags::SpatialVelocity<DataType, 3>,
hydro::Tags::DivergenceCleaningField<DataType>>{});
const auto expected_magnetic_field =
make_with_value<tnsr::I<DataType, 3>>(used_for_size, 0.0);
const auto expected_div_clean_field =
make_with_value<Scalar<DataType>>(used_for_size, 0.0);
CHECK_ITERABLE_APPROX(magnetic_field, expected_magnetic_field);
CHECK_ITERABLE_APPROX(
get<hydro::Tags::DivergenceCleaningField<DataType>>(
another_disk.variables(
coords,
tmpl::list<hydro::Tags::DivergenceCleaningField<DataType>>{})),
make_with_value<Scalar<DataType>>(used_for_size, 0.0));
CHECK_ITERABLE_APPROX(div_clean_field, expected_div_clean_field);
}
} // namespace

Expand All @@ -196,7 +194,7 @@ SPECTRE_TEST_CASE("Unit.PointwiseFunctions.AnalyticData.GrMhd.MagFmDisk",
test_move();

test_variables(std::numeric_limits<double>::signaling_NaN());
// test_variables(DataVector(5));
test_variables(DataVector(5));

// #ifdef SPECTRE_DEBUG
// CHECK_THROWS_WITH(
Expand Down

0 comments on commit ff4e818

Please sign in to comment.