public void can_unpack_a_nupkg_into_the_current_directory() { Directory.Exists(PathToTemp("MarkdownSharp-1.13.0.0")).ShouldBeFalse(); // Unpack(nupkg [, directory to unpack into]); Moo.Unpack(PathToContent("packages", "MarkdownSharp.1.13.0.0.nupkg"), TempDirectory); Directory.Exists(PathToTemp("MarkdownSharp-1.13.0.0")).ShouldBeTrue(); File.Exists(PathToTemp("MarkdownSharp-1.13.0.0", "MarkdownSharp.nuspec")).ShouldBeTrue(); File.Exists(PathToTemp("MarkdownSharp-1.13.0.0", "lib", "35", "MarkdownSharp.dll")).ShouldBeTrue(); }
public void unpacks_into_properly_named_directory_even_if_nupkg_is_named_wrong() { Directory.Exists(PathToTemp("MarkdownSharp-1.13.0.0")).ShouldBeFalse(); // Unpack(nupkg [, directory to unpack into]); Moo.Unpack(PathToContent("packages", "unnamed.nupkg"), TempDirectory); Directory.Exists(PathToTemp("MarkdownSharp-1.13.0.0")).ShouldBeTrue(); File.Exists(PathToTemp("MarkdownSharp-1.13.0.0", "MarkdownSharp.nuspec")).ShouldBeTrue(); File.Exists(PathToTemp("MarkdownSharp-1.13.0.0", "lib", "35", "MarkdownSharp.dll")).ShouldBeTrue(); }
public static object Run(string[] args) { var package = Moo.Unpack(args[0]); return(string.Format("Unpacked {0}", package.IdAndVersion)); }