Skip to content

Commit 07459a0

Browse files
author
Vasileios Karakasis
authored
Merge pull request #1755 from lucamar/fix-cp2k81
[test] Adjust regex patterns for CP2K 8.1
2 parents 3170570 + 13bcc5a commit 07459a0

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

cscs-checks/apps/cp2k/cp2k_check.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,17 @@ def __init__(self):
1414
self.executable = 'cp2k.psmp'
1515
self.executable_opts = ['H2O-256.inp']
1616

17-
energy = sn.extractsingle(r'\s+ENERGY\| Total FORCE_EVAL \( QS \) '
18-
r'energy \(a\.u\.\):\s+(?P<energy>\S+)',
19-
self.stdout, 'energy', float, item=-1)
17+
energy = sn.extractsingle(
18+
r'\s+ENERGY\| Total FORCE_EVAL \( QS \) '
19+
r'energy [\[\(]a\.u\.[\]\)]:\s+(?P<energy>\S+)',
20+
self.stdout, 'energy', float, item=-1
21+
)
2022
energy_reference = -4404.2323
2123
energy_diff = sn.abs(energy-energy_reference)
2224
self.sanity_patterns = sn.all([
2325
sn.assert_found(r'PROGRAM STOPPED IN', self.stdout),
2426
sn.assert_eq(sn.count(sn.extractall(
25-
r'(?P<step_count>STEP NUM)',
27+
r'(?i)(?P<step_count>STEP NUMBER)',
2628
self.stdout, 'step_count')), 10),
2729
sn.assert_lt(energy_diff, 1e-4)
2830
])

0 commit comments

Comments
 (0)