Skip to content

Commit

Permalink
fixing comparer tests
Browse files Browse the repository at this point in the history
  • Loading branch information
tkstanczak committed Mar 18, 2019
1 parent d7621b6 commit 151ddb6
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/Nethermind/Nethermind.Network.Test/PeerComparerTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public void Can_sort_by_trusted()
Node c = new Node(TestItem.PublicKeyC, "127.0.0.1", 30303);
Peer peerC = new Peer(c);

Assert.AreEqual(1, _comparer.Compare(peerA, peerB));
Assert.AreEqual(-1, _comparer.Compare(peerA, peerB));
Assert.AreEqual(0, _comparer.Compare(peerB, peerC));
}

Expand All @@ -71,9 +71,9 @@ public void Can_sort_by_Reputation()
_statsManager.GetCurrentReputation(b).Returns(50);
_statsManager.GetCurrentReputation(c).Returns(200);

Assert.AreEqual(1, _comparer.Compare(peerA, peerB));
Assert.AreEqual(-1, _comparer.Compare(peerA, peerC));
Assert.AreEqual(-1, _comparer.Compare(peerB, peerC));
Assert.AreEqual(-1, _comparer.Compare(peerA, peerB));
Assert.AreEqual(1, _comparer.Compare(peerA, peerC));
Assert.AreEqual(1, _comparer.Compare(peerB, peerC));
Assert.AreEqual(0, _comparer.Compare(peerA, peerA));
Assert.AreEqual(0, _comparer.Compare(peerB, peerB));
Assert.AreEqual(0, _comparer.Compare(peerC, peerC));
Expand Down

0 comments on commit 151ddb6

Please sign in to comment.