public void WhenGivenStringArrayProperty_FormatsProperly() { var actual = ArgumentsBuilderExtension.GetArgumentFromStringArrayProperty(StringsProperty, new string[] { "tubo1", "tubo2" }, isSecret: false); CollectionAssert.AreEqual(actual, new DockerArgument[] { new DockerArgument("--strings", "tubo1", DockerArgumentQuoting.Quoted), new DockerArgument("--strings", "tubo2", DockerArgumentQuoting.Quoted) }); }
public void WhenGivenNull_EmptyArrayReturned() { var actual = ArgumentsBuilderExtension.GetArgumentFromStringArrayProperty(StringsProperty, null); Assert.That(actual, Is.Empty); }
public void WhenGivenStringArrayProperty_FormatsProperly() { var actual = ArgumentsBuilderExtension.GetArgumentFromStringArrayProperty(StringsProperty, new string[] { "tubo1", "tubo2" }); Assert.AreEqual(actual.ToArray(), new string[] { "--strings \"tubo1\"", "--strings \"tubo2\"" }); }