Task("JS-Tests")
.IsDependentOn("NPM-Install")
.DoesForEach(GetFiles("../root/*/karma.conf.js"), (suite) =>
{
var settings = new NpmRunScriptSettings { ScriptName = "test", WorkingDirectory = "../root" };
settings = settings.WithArguments(suite).WithArguments(suite).WithArguments("--single-run");
NpmRunScript(settings);
});
Task("JS-Tests")
.IsDependentOn("NPM-Install")
.DoesForEach(GetFiles("../root/*/karma.conf.js"), (suite) =>
{
var settings = new NpmRunScriptSettings { ScriptName = "test", WorkingDirectory = "../root" };
settings = Cake.Npm.RunScript.NpmRunScriptSettingsExtensions.WithArguments(settings, suite.ToString());
settings = Cake.Npm.RunScript.NpmRunScriptSettingsExtensions.WithArguments(settings, "--single-run");
NpmRunScript(settings);
});
Is there something special I need to do in my build script to use .WithArguments as an extension method?