public void testScoreVector() {
ItemScorer pred = new ConstantItemScorer(5);
MutableSparseVector v = MutableSparseVector.create(1, 2, 3, 5, 7);
pred.score(42, v);
assertThat(v.keySet(), contains(1L, 2L, 3L, 5L, 7L));
assertThat(v.values(), everyItem(equalTo(5.0)));
}
}