public void testFile() throws Exception {
UserSimilarity userSimilarity = new PearsonCorrelationSimilarity(model);
UserNeighborhood neighborhood = new NearestNUserNeighborhood(3, userSimilarity, model);
Recommender recommender = new GenericUserBasedRecommender(model, neighborhood, userSimilarity);
assertEquals(1, recommender.recommend(123, 3).size());
assertEquals(0, recommender.recommend(234, 3).size());
assertEquals(1, recommender.recommend(345, 3).size());
// Make sure this doesn't throw an exception
model.refresh(null);
}