Skip to content
This repository was archived by the owner on Nov 17, 2026. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,11 @@ packmol changelog
[badge-fix]: https://img.shields.io/badge/Fix-purple.svg
[badge-info]: https://img.shields.io/badge/Info-gray.svg

Version 21.2.2-DEV
Version 21.2.3-DEV
--------------
- ![INFO][badge-info] Update versions of CellListMap.jl and PDBTools.jl packages in test infraestructure.

Version 21.2.2
--------------
- ![INFO][badge-info] Fix code typos.
- ![INFO][badge-info] Add changelog verification CI run.
Expand Down
4 changes: 4 additions & 0 deletions testing/Project.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
[compat]
CellListMap = "0.10.2"
PDBTools = "3.27.0"

[deps]
CellListMap = "69e1c6dd-3888-40e6-b3c8-31ac5f578864"
PDBTools = "e29189f1-7114-4dbd-93d0-c5673a921a58"
9 changes: 5 additions & 4 deletions testing/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,15 @@ struct MinimumDistance
j::Int
d::Float64
end
function update_mind(i, j, d2, pdb, md::MinimumDistance)
function update_mind(pair, pdb, md::MinimumDistance)
(; i, j, d2) = pair
residue(pdb[i]) == residue(pdb[j]) && return md
d = sqrt(d2)
return d < md.d ? MinimumDistance(i, j, d) : md
end
CellListMap.reducer(md1::MinimumDistance, md2::MinimumDistance) = md1.d < md2.d ? md1 : md2
CellListMap.reducer!(md1::MinimumDistance, md2::MinimumDistance) = md1.d < md2.d ? md1 : md2
CellListMap.copy_output(md::MinimumDistance) = md
CellListMap.reset_output(::MinimumDistance) = MinimumDistance(0, 0, +Inf)
CellListMap.reset_output!(::MinimumDistance) = MinimumDistance(0, 0, +Inf)

function check_mind(input_file::String)
tolerance = nothing
Expand Down Expand Up @@ -63,7 +64,7 @@ function check_mind(input_file::String)
cutoff = tolerance * 1.5,
output = MinimumDistance(0, 0, +Inf),
)
mind = map_pairwise((x,y,i,j,d2,md) -> update_mind(i, j, d2, pdb, md), sys)
mind = pairwise!((pair,md) -> update_mind(pair, pdb, md), sys)
if (mind.d < (1 - precision) * tolerance)
error("""\n

Expand Down
Loading