CloneSet216


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
25230.990class_member_declaration
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
12520
src/NHibernate.Test/NHSpecificTest/NH1959/Fixture.cs
22547
src/NHibernate.Test/NHSpecificTest/NH1959/Fixture.cs
Clone Instance
1
Line Count
25
Source Line
20
Source File
src/NHibernate.Test/NHSpecificTest/NH1959/Fixture.cs

                [Test]
                public void StartWithEmptyDoAddAndRemove()
                {
                        ClassB b = new ClassB();
                        ClassA a = new ClassA();
                        using (ISession s = OpenSession())
                        using (ITransaction tx = s.BeginTransaction())
                        {
                                s.Save(a);
                                s.Save(b);
                                tx.Commit();
                        }

                        using (ISession s = OpenSession())
                        using (ITransaction tx = s.BeginTransaction())
                        {
                                ClassA loadedA = s.Get < ClassA > (a.Id);
                                ClassB loadedB = s.Get < ClassB > (b.Id);
                                loadedA.TheBag.Add(loadedB);
                                loadedA.TheBag.Remove(loadedB);
                                tx.Commit();
                        }

                        using (ISession s = OpenSession())
                                Assert.AreEqual(0, s.Get < ClassA > (a.Id).TheBag.Count);
                }



Clone Instance
2
Line Count
25
Source Line
47
Source File
src/NHibernate.Test/NHSpecificTest/NH1959/Fixture.cs

                [Test]
                public void StartWithEmptyDoAddAndRemoveAt()
                {
                        ClassB b = new ClassB();
                        ClassA a = new ClassA();
                        using (ISession s = OpenSession())
                        using (ITransaction tx = s.BeginTransaction())
                        {
                                s.Save(a);
                                s.Save(b);
                                tx.Commit();
                        }

                        using (ISession s = OpenSession())
                        using (ITransaction tx = s.BeginTransaction())
                        {
                                ClassA loadedA = s.Get < ClassA > (a.Id);
                                ClassB loadedB = s.Get < ClassB > (b.Id);
                                loadedA.TheBag.Add(loadedB);
                                loadedA.TheBag.RemoveAt(0);
                                tx.Commit();
                        }

                        using (ISession s = OpenSession())
                                Assert.AreEqual(0, s.Get < ClassA > (a.Id).TheBag.Count);
                }



Clone AbstractionParameter Count: 3Parameter Bindings

[Test]
public void [[#variable298677a0]]()
{
   ClassB b = new ClassB();
   ClassA a = new ClassA();
   using (ISession s = OpenSession())
      using (ITransaction tx = s.BeginTransaction())
      {
         s.Save(a);
         s.Save(b);
         tx.Commit();
      }
   using (ISession s = OpenSession())
      using (ITransaction tx = s.BeginTransaction())
      {
         ClassA loadedA = s.Get < ClassA > (a.Id);
         ClassB loadedB = s.Get < ClassB > (b.Id);
         loadedA.TheBag.Add(loadedB);
         loadedA.TheBag. [[#variable298676e0]]( [[#variable29867660]]);
         tx.Commit();
      }
   using (ISession s = OpenSession())
      Assert.AreEqual(0, s.Get < ClassA > (a.Id).TheBag.Count);
}

 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#298677a0]]
StartWithEmptyDoAddAndRemove 
12[[#298677a0]]
StartWithEmptyDoAddAndRemoveAt 
21[[#298676e0]]
Remove 
22[[#298676e0]]
RemoveAt 
31[[#29867660]]
loadedB 
32[[#29867660]]
0