public void Should_Set_ThrowOnError_By_Default()
            {
                // Given, When
                var settings = new SvnAddSettings();

                // Then
                Assert.True(settings.ThrowOnError);
            }
            public void Should_Set_ThrowOnWarning_By_Default()
            {
                // Given, When
                var settings = new SvnAddSettings();

                // Then
                Assert.False(settings.ThrowOnWarning);
            }
            public void Should_Not_Ignore_By_Default()
            {
                // Given, When
                var settings = new SvnAddSettings();

                // Then
                Assert.True(settings.Ignore);
            }
            public void Should_Not_Auto_Props_By_Default()
            {
                // Given, When
                var settings = new SvnAddSettings();

                // Then
                Assert.True(settings.AutoProperties);
            }
            public void Should_Not_Force_By_Default()
            {
                // Given, When
                var settings = new SvnAddSettings();

                // Then
                Assert.False(settings.Force);
            }
            public void Should_Add_Parents_By_Default()
            {
                // Given, When
                var settings = new SvnAddSettings();

                // Then
                Assert.True(settings.AddParents);
            }
            public void Should_Set_Infity_Depth_By_Default()
            {
                // Given, When
                var settings = new SvnAddSettings();

                // Then
                Assert.Equal(SvnDepth.Infinity, settings.Depth);
            }
예제 #8
0
 internal SvnAdderFixture()
 {
     Environment   = Substitute.For <ICakeEnvironment>();
     SvnClient     = Substitute.For <ISvnClient>();
     Settings      = new SvnAddSettings();
     DirectoryPath = new DirectoryPath(@"C:\test\");
     FilePath      = new FilePath(@"C:\test\test.cs");
     GetSvnClient  = () => SvnClient;
 }
예제 #9
0
 /// <inheritdoc/>
 public bool Add(string fileOrDirectoryPath, SvnAddSettings settings)
 {
     return(Add(fileOrDirectoryPath, settings.ToSvnAddArgs()));
 }
        public static bool SvnAddDirectory(this ICakeContext context, DirectoryPath directory, SvnAddSettings settings)
        {
            var adder = new SvnAdder(context.Environment, SvnClientFactoryMethod);

            return(adder.Add(directory, settings ?? new SvnAddSettings()));
        }
        public static bool SvnAddFile(this ICakeContext context, FilePath file, SvnAddSettings settings)
        {
            var adder = new SvnAdder(context.Environment, SvnClientFactoryMethod);

            return(adder.Add(file, settings ?? new SvnAddSettings()));
        }