public void Should_Add_Default_Arguments() { var fixture = new JekyllBuildCommandFixture(); var result = fixture.Run(); result.Args.Should().Be("exec jekyll build"); }
public void Should_Add_Source_To_Arguments_If_Not_Null() { var fixture = new JekyllBuildCommandFixture { Settings = { Source = @"c:\sourceDir" }, }; var result = fixture.Run(); result.Args.Should().Be(@"exec jekyll build --source ""c:/sourceDir"""); }
public void Should_Add_Multiple_Configuration_To_Arguments_If_Not_Null() { var fixture = new JekyllBuildCommandFixture { Settings = { Configuration = new [] { @"c:\_config1.yml", @"c:\_config2.yml" } }, }; var result = fixture.Run(); result.Args.Should().Be(@"exec jekyll build --config ""c:/_config1.yml"" ""c:/_config2.yml"""); }
public void Should_Add_LogLevel_To_Arguments_If_Not_Null(JekyllLogLevel?logLevel, string expected) { var fixture = new JekyllBuildCommandFixture { Settings = { LogLevel = logLevel }, }; var result = fixture.Run(); result.Args.Should().Be($"exec jekyll build{expected}"); }
public void Should_Add_Layouts_To_Arguments_If_Not_Null() { var fixture = new JekyllBuildCommandFixture { Settings = { Layouts = @"c:\layoutsDir" }, }; var result = fixture.Run(); result.Args.Should().Be(@"exec jekyll build --layouts ""c:/layoutsDir"""); }
public void Should_Add_Trace_To_Arguments_If_Not_Null(bool?trace, string expected) { var fixture = new JekyllBuildCommandFixture { Settings = { Trace = trace }, }; var result = fixture.Run(); result.Args.Should().Be($"exec jekyll build{expected}"); }
public void Should_Add_StrictFrontMatter_To_Arguments_If_Not_Null(bool?strictFrontMatter, string expected) { var fixture = new JekyllBuildCommandFixture { Settings = { StrictFrontMatter = strictFrontMatter }, }; var result = fixture.Run(); result.Args.Should().Be($"exec jekyll build{expected}"); }
public void Should_Add_Multiple_Plugin_To_Arguments_If_Not_Null() { var fixture = new JekyllBuildCommandFixture { Settings = { Plugins = new [] { @"c:\pluginDir1", @"c:\pluginDir2" } }, }; var result = fixture.Run(); result.Args.Should().Be(@"exec jekyll build --plugins ""c:/pluginDir1"" ""c:/pluginDir2"""); }
public void Should_Add_DisableDiskCache_To_Arguments_If_Not_Null(bool?disableDiskCache, string expected) { var fixture = new JekyllBuildCommandFixture { Settings = { DisableDiskCache = disableDiskCache }, }; var result = fixture.Run(); result.Args.Should().Be($"exec jekyll build{expected}"); }
public void Should_Add_ForcePolling_To_Arguments_If_Not_Null(bool?forcePolling, string expected) { var fixture = new JekyllBuildCommandFixture { Settings = { ForcePolling = forcePolling }, }; var result = fixture.Run(); result.Args.Should().Be($"exec jekyll build{expected}"); }
public void Should_Add_BaseUrl_To_Arguments_If_Not_Null() { var fixture = new JekyllBuildCommandFixture { Settings = { BaseUrl = @"http://*****:*****@"exec jekyll build --baseurl ""http://localhost:8042"""); }
public void Should_Add_Watch_To_Arguments_If_Not_Null(bool?regeneration, string expected) { var fixture = new JekyllBuildCommandFixture { Settings = { Watch = regeneration }, }; var result = fixture.Run(); result.Args.Should().Be($"exec jekyll build{expected}"); }
public void Should_Add_LimitPosts_To_Arguments_If_Not_Null(int?limitPosts, string expected) { var fixture = new JekyllBuildCommandFixture { Settings = { LimitPosts = limitPosts }, }; var result = fixture.Run(); result.Args.Should().Be($"exec jekyll build{expected}"); }
public void Should_Add_Destination_To_Arguments_If_Not_Null() { var fixture = new JekyllBuildCommandFixture { Settings = { Destination = @"c:\destinationDir" }, }; var result = fixture.Run(); result.Args.Should().Be(@"exec jekyll build --destination ""c:/destinationDir"""); }
public void Should_Throw_If_Settings_Are_Null() { var fixture = new JekyllBuildCommandFixture { Settings = null, }; Action action = () => fixture.Run(); action.Should().Throw <ArgumentNullException>() .Which.ParamName.Should().Be("settings"); }
public void Should_Add_Default_Arguments_When_Bundler_Is_Disabled() { var fixture = new JekyllBuildCommandFixture { Settings = { DoNotUseBundler = true }, }; fixture.GivenJekyllToolExist(); var result = fixture.Run(); result.Args.Should().Be("build"); }