本文整理匯總了C#中Topics.Radical.ChangeTracking.ChangeTrackingService.GetChangeSet方法的典型用法代碼示例。如果您正苦於以下問題:C# ChangeTrackingService.GetChangeSet方法的具體用法?C# ChangeTrackingService.GetChangeSet怎麽用?C# ChangeTrackingService.GetChangeSet使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Topics.Radical.ChangeTracking.ChangeTrackingService
的用法示例。
在下文中一共展示了ChangeTrackingService.GetChangeSet方法的9個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。
示例1: after_Add_getChangeSet_contains_change
public void after_Add_getChangeSet_contains_change()
{
IChangeTrackingService svc = new ChangeTrackingService();
PersonCollection p = new PersonCollection( svc );
p.Add( new Person( svc, false ) );
p.Add( new Person( svc, false ) );
IChangeSet cSet = svc.GetChangeSet();
cSet.Count.Should().Be.EqualTo( 2 );
}
示例2: afterPropertyChanges_getChangeSet_contains_change
public void afterPropertyChanges_getChangeSet_contains_change()
{
ChangeTrackingService svc = new ChangeTrackingService();
Person p = new Person( svc, false );
p.Name = "Mauro";
p.Name = "Andrea";
IChangeSet cSet = svc.GetChangeSet();
Assert.AreEqual<Int32>( 2, cSet.Count );
}
示例3: service_after_add_getChangeSet_return_valid_cSet
public void service_after_add_getChangeSet_return_valid_cSet()
{
RejectCallback<String> cb = cv => { };
Object fakeOwner = new Object();
String change = String.Empty;
IChange expected = new PropertyValueChange<String>( fakeOwner, "property-name", change, cb );
ChangeTrackingService svc = new ChangeTrackingService();
svc.Add( expected, AddChangeBehavior.RedoRequest );
IChangeSet cSet = svc.GetChangeSet();
Assert.AreEqual<IChange>( expected, cSet.First() );
}
示例4: service_getChangeSet_returns_valid_cSet
public void service_getChangeSet_returns_valid_cSet()
{
Int32 expected = 2;
Int32 actual = 0;
ChangeTrackingService svc = new ChangeTrackingService();
Person p = new Person( svc, true );
p.Name = "Mauro";
p.Name = "Mauro";
p.Name = "Foo";
IChangeSet cSet = svc.GetChangeSet();
actual = cSet.Count;
Assert.AreEqual<Int32>( expected, actual );
}
示例5: service_getChangeSet_with_valid_iChangeSetFilter
public void service_getChangeSet_with_valid_iChangeSetFilter()
{
Int32 expected = 2;
Int32 actual = 0;
IChangeSetFilter mock = MockRepository.GenerateMock<IChangeSetFilter>();
mock.Expect( f => f.ShouldInclude( null ) )
.IgnoreArguments()
.Repeat.Times( 2 )
.Return( true );
ChangeTrackingService svc = new ChangeTrackingService();
Person p = new Person( svc, true );
p.Name = "Mauro";
p.Name = "Mauro";
p.Name = "Foo";
IChangeSet cSet = svc.GetChangeSet( mock );
actual = cSet.Count;
mock.VerifyAllExpectations();
Assert.AreEqual<Int32>( expected, actual );
}
示例6: service_getChangeSet_with_null_iChangeSetFilter
public void service_getChangeSet_with_null_iChangeSetFilter()
{
ChangeTrackingService svc = new ChangeTrackingService();
svc.GetChangeSet( null );
}
示例7: service_getChangeSet_with_null_iChangeSetFilter_argumentNullExeption
public void service_getChangeSet_with_null_iChangeSetFilter_argumentNullExeption()
{
ChangeTrackingService svc = new ChangeTrackingService();
svc.GetChangeSet( null );
}
示例8: service_getChangeSet_when_is_not_changed_empty_cSet
public void service_getChangeSet_when_is_not_changed_empty_cSet()
{
ChangeTrackingService svc = new ChangeTrackingService();
IChangeSet cSet = svc.GetChangeSet();
Assert.IsNotNull( cSet );
Assert.AreEqual<Int32>( 0, cSet.Count );
}
示例9: service_getChangeSet_returns_valid_cSet
public void service_getChangeSet_returns_valid_cSet()
{
Int32 expected = 3;
Int32 actual = 0;
ChangeTrackingService svc = new ChangeTrackingService();
PersonCollection p = new PersonCollection( svc );
p.Add( new Person( null, false ) );
p.Add( new Person( null, false ) );
p.Move( 0, 1 );
IChangeSet cSet = svc.GetChangeSet();
actual = cSet.Count;
Assert.AreEqual<Int32>( expected, actual );
}