Skip to content

Commit

Permalink
[UnitTests] Add check for multiple sticking species
Browse files Browse the repository at this point in the history
  • Loading branch information
ischoegl committed Mar 7, 2022
1 parent b742a96 commit 547c737
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions interfaces/cython/cantera/test/test_kinetics.py
Expand Up @@ -1573,6 +1573,15 @@ def test_modify_interface(self):
self.assertNotAlmostEqual(k1, k2)
self.assertNear(k2, k3)

def test_invalid_sticking(self):
yaml = """
equation: OH + Csoot-H + CB-CB3 + CO => Csoot-* + 2 CO + H2
sticking-coefficient: {A: 0.13, b: 0.0, Ea: 0.0}"""
surf = ct.Interface("haca2.yaml", "soot_interface")
rxn = ct.Reaction.from_yaml(yaml, surf)
with pytest.raises(ct.CanteraError, match="non-interface species"):
surf.add_reaction(rxn)

def test_modify_sticking(self):
gas = ct.Solution("ptcombust.yaml", "gas")
surf = ct.Interface("ptcombust.yaml", "Pt_surf", [gas])
Expand Down

0 comments on commit 547c737

Please sign in to comment.