Exemple #1
0
 private FakeChange(TfsChangeType tfsChangeType, TfsItemType itemType, string serverItem, int deletionId = 0, string renamedFrom = null)
 {
     _tfsChangeType = tfsChangeType;
     _tfsItemType   = itemType;
     _serverItem    = serverItem;
     _deletionId    = deletionId;
     _renamedFrom   = renamedFrom;
     _itemId        = ++_maxItemId;
 }
Exemple #2
0
 public FakeChangesetBuilder Change(TfsChangeType changeType, TfsItemType itemType, string tfsPath, string contents = null)
 {
     _changeset.Changes.Add(new ScriptedChange
     {
         ChangeType     = changeType,
         ItemType       = itemType,
         RepositoryPath = tfsPath,
         Content        = contents
     });
     return(this);
 }
Exemple #3
0
 public FakeChangesetBuilder Change(TfsChangeType changeType, TfsItemType itemType, string tfsPath, string contents, int?itemId = null)
 {
     return(Change(changeType, itemType, tfsPath, Encoding.UTF8.GetBytes(contents), itemId));
 }
 private TfsTreeEntry item(TfsItemType itemType, string gitPath)
 {
     return(new TfsTreeEntry(gitPath, mocks.StrictMock <IItem>().Tap(mockItem => mockItem.Stub(x => x.ItemType).Return(itemType))));
 }
 private TfsTreeEntry item(TfsItemType itemType, string gitPath)
 {
     return new TfsTreeEntry(gitPath, mocks.StrictMock<IItem>().Tap(mockItem => mockItem.Stub(x => x.ItemType).Return(itemType)));
 }
Exemple #6
0
 private TfsTreeEntry item(TfsItemType itemType, string gitPath)
 {
     return(new TfsTreeEntry(gitPath, mocks.OneOf <IItem>().Tap(mockItem => Mock.Get(mockItem).Setup(x => x.ItemType).Returns(itemType))));
 }
Exemple #7
0
 public FakeChangesetBuilder Change(TfsChangeType changeType, TfsItemType itemType, string tfsPath, string contents = null)
 {
     _changeset.Changes.Add(new ScriptedChange
     {
         ChangeType = changeType,
         ItemType = itemType,
         RepositoryPath = tfsPath,
         Content = contents
     });
     return this;
 }