Skip to content

Commit

Permalink
Update naming/formatting in thermo consistency tests
Browse files Browse the repository at this point in the history
  • Loading branch information
speth authored and ischoegl committed Jun 10, 2022
1 parent 0c2cd31 commit 857ae8c
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 12 deletions.
14 changes: 7 additions & 7 deletions test/data/consistency-cases.yaml
Expand Up @@ -32,7 +32,7 @@ ideal-molal-solution:
known-failures:
g_eq_h_minus_Ts:
"Implementations of g and s are inconsistent. See GitHub Issue #1300"
gk_eq_hk_minus_T_times_sk:
gk_eq_hk_minus_T_sk:
"Implementations of g and s are inconsistent. See GitHub Issue #1300"
cv_eq_.+: cv not implemented
cp_eq_dsdT_const_p_times_T:
Expand Down Expand Up @@ -78,8 +78,8 @@ binary-solution-tabulated:
v_eq_sum_vk_Xk: "Inconsistent results. See GitHub Issue #1302"
h_eq_sum_hk_Xk: "Inconsistent results. See GitHub Issue #1302"
s_eq_sum_sk_Xk: "Problems near composition limit. See GitHub Issue #1303"
gk_eq_hk_minus_T_times_sk: "Problems near composition limit. See GitHub Issue #1303"
gk0_eq_hk0_minus_T_times_sk0/[34]:
gk_eq_hk_minus_T_sk: "Problems near composition limit. See GitHub Issue #1303"
gk0_eq_hk0_minus_T_sk0/[34]:
"Problems near composition limit. See GitHub Issue #1303"
chem_potentials_to_activities/3:
"Problems near composition limit. See GitHub Issue #1303"
Expand Down Expand Up @@ -199,7 +199,7 @@ lattice:
phase: Li7Si3-interstitial
known-failures:
_sum_.+_Xk: "Implementation is wrong. See GitHub Issue #1309"
gk_eq_hk_minus_T_times_sk: "Implementation is wrong. See GitHub Issue #1309"
gk_eq_hk_minus_T_sk: "Implementation is wrong. See GitHub Issue #1309"
standard_gibbs_nondim: "Implementation is wrong. See GitHub Issue #1309"
chem_potentials_to_activities: "Implementation is wrong. See GitHub Issue #1309"
states:
Expand All @@ -214,7 +214,7 @@ compound-lattice:
known-failures:
_sum_.+_Xk: "LatticePhase implementation is wrong. See GitHub Issue #1309"
h_eq_u_plus_Pv: "Implementation is inconsistent. See GitHub Issue #1310"
gk_eq_hk_minus_T_times_sk: "Implementation is inconsistent. See GitHub Issue #1310"
gk_eq_hk_minus_T_sk: "Implementation is inconsistent. See GitHub Issue #1310"
chem_potentials_to_activities:
"LatticePhase implementation is wrong. See GitHub Issue #1309"
activity_coeffs: "See GitHub Issue #1309"
Expand All @@ -239,7 +239,7 @@ ideal-surface:
atol_v: 1e-7
known-failures:
h_eq_u_plus_Pv: "Definition of volume is unclear. See GitHub Issue #1312"
gk_eq_hk_minus_T_times_sk:
gk_eq_hk_minus_T_sk:
"Implementation of s_k is incorrect. See GitHub Issue #1313"
s_eq_sum_sk_Xk:
"Implementation of s_k is incorrect. See GitHub Issue #1313"
Expand Down Expand Up @@ -273,7 +273,7 @@ liquid-water-IAPWS95:
rtol_fd: 5e-3 # Limited agreement for Maxwell relations
known-failures:
h_eq_u_plus_Pv: "Error in internal energy calculation. See GitHub Issue #1315"
hk_eq_uk_plus_P_times_vk:
hk_eq_uk_plus_P_vk:
"Error in internal energy calculation. See GitHub Issue #1315"
cv_eq_dudT: "Error in internal energy calculation. See GitHub Issue #1315"
hk0_eq_uk0_plus_p_vk0:
Expand Down
10 changes: 5 additions & 5 deletions test/thermo/consistency.cpp
Expand Up @@ -99,7 +99,7 @@ TEST_P(TestConsistency, g_eq_h_minus_Ts) {
EXPECT_NEAR(g, h - T * s, atol);
}

TEST_P(TestConsistency, hk_eq_uk_plus_P_times_vk)
TEST_P(TestConsistency, hk_eq_uk_plus_P_vk)
{
vector_fp hk(nsp), uk(nsp), vk(nsp);
try {
Expand All @@ -114,7 +114,7 @@ TEST_P(TestConsistency, hk_eq_uk_plus_P_times_vk)
}
}

TEST_P(TestConsistency, gk_eq_hk_minus_T_times_sk)
TEST_P(TestConsistency, gk_eq_hk_minus_T_sk)
{
vector_fp gk(nsp), hk(nsp), sk(nsp);
try {
Expand Down Expand Up @@ -205,7 +205,7 @@ TEST_P(TestConsistency, cp_eq_dhdT)
double h2 = phase->enthalpy_mole();
double cp2 = phase->cp_mole();
double cp_mid = 0.5 * (cp1 + cp2);
double cp_fd = (h2 - h1)/dT;
double cp_fd = (h2 - h1) / dT;
EXPECT_NEAR(cp_fd, cp_mid, max({rtol_fd * cp_mid, rtol_fd * cp_fd, atol}));
}

Expand All @@ -223,7 +223,7 @@ TEST_P(TestConsistency, cv_eq_dudT)
double u2 = phase->intEnergy_mole();
double cv2 = phase->cv_mole();
double cv_mid = 0.5 * (cv1 + cv2);
double cv_fd = (u2 - u1)/dT;
double cv_fd = (u2 - u1) / dT;
EXPECT_NEAR(cv_fd, cv_mid, max({rtol_fd * cv_mid, rtol_fd * cv_fd, atol}));
}

Expand Down Expand Up @@ -362,7 +362,7 @@ TEST_P(TestConsistency, standard_gibbs_nondim)
GTEST_SKIP() << err.getMethod() << " threw NotImplementedError";
}
for (size_t k = 0; k < nsp; k++) {
EXPECT_NEAR(g0_RT[k] * RT , mu0[k], atol);
EXPECT_NEAR(g0_RT[k] * RT , mu0[k], atol) << "k = " << k;
}
}

Expand Down

0 comments on commit 857ae8c

Please sign in to comment.