Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Renamed SimilarReviews to FindSimilarReviews

  • Loading branch information...
commit b960e02da623fbe27efb51eda03bf6c5ba393490 1 parent 2576cfc
@robertgreiner authored
View
4 Recommender.Tests/Reviews/ReviewerTests.cs
@@ -47,7 +47,7 @@ public void TwoSimilarReviewersShouldHaveOneLikeReview()
{
var r1 = ReviewerBuilder.BuildOneReviewMax();
var r2 = ReviewerBuilder.BuildOneReviewMin();
- Assert.AreEqual(1, r1.SimilarReviews(r2.Reviews).Count);
+ Assert.AreEqual(1, r1.FindSimilarReviews(r2.Reviews).Count);
}
[Test]
@@ -55,7 +55,7 @@ public void ReviewersThatHaveTheSameTasteShouldHaveAllSimilarItems()
{
var r1 = ReviewerBuilder.BuildReviewer1();
var r2 = ReviewerBuilder.BuildReviewer1();
- Assert.AreEqual(6, r1.SimilarReviews(r2.Reviews).Count);
+ Assert.AreEqual(6, r1.FindSimilarReviews(r2.Reviews).Count);
}
}
}
View
2  Recommender/EuclideanDistance.cs
@@ -20,7 +20,7 @@ public EuclideanDistance(Reviewer r1, Reviewer r2)
public double Score()
{
- var similarReviews = R1.SimilarReviews(R2.Reviews);
+ var similarReviews = R1.FindSimilarReviews(R2.Reviews);
if (similarReviews.Count == 0)
{
View
2  Recommender/Reviews/Reviewer.cs
@@ -20,7 +20,7 @@ public void AddReview(string title, double score)
Reviews.Add(title, score);
}
- public List<string> SimilarReviews(Dictionary<string, double> compareTo)
+ public List<string> FindSimilarReviews(Dictionary<string, double> compareTo)
{
return (from r in Reviews where compareTo.ContainsKey(r.Key) select r.Key).ToList();
}
Please sign in to comment.
Something went wrong with that request. Please try again.