コード例 #1
0
ファイル: Comparisons.cs プロジェクト: yongyongjijip1/mpir
 public void RationalGetHashCodeTest()
 {
     using (var a = new HugeRational("-222509832503450298345029835740293845721/115756986668303657898962467957"))
     {
         Assert.AreNotEqual(0, a.GetHashCode());
         Assert.AreEqual(a.GetHashCode(), (a + 0).GetHashCode());
         Assert.AreNotEqual(a.GetHashCode(), (-a).GetHashCode());
     }
 }
コード例 #2
0
ファイル: Comparisons.cs プロジェクト: romance-ii/mpir
 public void RationalGetHashCodeTest()
 {
     using (var a = new HugeRational("-222509832503450298345029835740293845721/115756986668303657898962467957"))
     {
         Assert.AreNotEqual(0, a.GetHashCode());
         Assert.AreEqual(a.GetHashCode(), (a + 0).GetHashCode());
         Assert.AreNotEqual(a.GetHashCode(), (-a).GetHashCode());
     }
 }