public override void Setup() { base.Setup(); fixture = new Fixture(); repositorySubstitute = Substitute.For<IRepository>(); gitFacadeSubstitute = Substitute.For<IGitFacade>(); gitFacadeSubstitute.NewRepository(Arg.Any<string>()).Returns(repositorySubstitute); }
public GitInitializeLocalRepositoryAction(ActionContext context, IGitFacade gitFacade) { Guard.That(context).IsNotNull(); Guard.That(gitFacade).IsNotNull(); this.context = context; this.gitFacade = gitFacade; exporterEmail = string.Format("vault-exporter@{0}", context.Parameters.CommitAuthorEmailDomain); }
public override void Setup() { base.Setup(); fixture = new Fixture(); repositorySubstitute = Substitute.For <IRepository>(); gitFacadeSubstitute = Substitute.For <IGitFacade>(); gitFacadeSubstitute.NewRepository(Arg.Any <string>()).Returns(repositorySubstitute); }
/// <summary> /// Initializes a new instance of the <see cref="Clone"/> class. /// </summary> /// <remarks>When no parameter is used in the constructor, instantiate the default</remarks> public Clone() { _gitFacade = new NGit(); }
/// <summary> /// Initializes a new instance of the <see cref="Clone"/> class. /// </summary> /// <param name="facade">IGitFacade interface</param> /// <remarks>Added to be able to unit test this class using a mock</remarks> public Clone(IGitFacade facade) { _gitFacade = facade; }
/// <summary> /// Initializes a new instance of the <see cref="Clone"/> class. /// </summary> /// <remarks>When no parameter is used in the constructor, instantiate the default</remarks> public Clone() { this.gitFacade = new NGitImplementation(); }
/// <summary> /// Initializes a new instance of the <see cref="Clone"/> class. /// </summary> /// <param name="facade">IGitFacade interface</param> /// <remarks>Added to be able to unit test this class using a mock</remarks> public Clone(IGitFacade facade) { this.gitFacade = facade; }