fix regression: failing test in test-replicate.R