public void Parameter() { Assert.AreEqual("3.4.5.6" + Environment.NewLine, TestHost.Execute("New-Object version \"3.4.5.6\"")); }
public void BuiltinType() { Assert.AreEqual("False" + Environment.NewLine, TestHost.Execute("New-Object bool")); }
public void WebClient() { Assert.AreEqual("System.Net.WebClient" + Environment.NewLine, TestHost.Execute("New-Object Net.WebClient")); }
public void ValueTypes() { Assert.AreEqual("False" + Environment.NewLine, TestHost.Execute("New-Object Boolean")); }
public void SystemPrefixIsOptional() { Assert.AreEqual("0.0" + Environment.NewLine, TestHost.Execute("New-Object Version")); }
public void CaseInsenstive() { Assert.AreEqual("0.0" + Environment.NewLine, TestHost.Execute("New-Object version")); }
public void CanCreateTypeWithNoParameters() { Assert.AreEqual("0.0" + Environment.NewLine, TestHost.Execute("New-Object System.Version")); }
private string RunTestVerboseOutputCommand(string parameters) { string command = "Test-VerboseOutput"; return(TestHost.Execute(command + " " + parameters)); }
public void TwoParentFolders() { string result = TestHost.Execute(string.Format(@"Split-Path parent1{0}child,parent2{0}child", Path.DirectorySeparatorChar)); Assert.AreEqual(string.Format(@"parent1{0}parent2{0}", Environment.NewLine), result); }
public void OneParentFolder() { string result = TestHost.Execute(string.Format(@"Split-Path 'parent{0}child'", Path.DirectorySeparatorChar)); Assert.AreEqual(@"parent" + Environment.NewLine, result); }
public void WebClient() { Assert.AreEqual(typeof(System.Net.WebClient).Name + Environment.NewLine, TestHost.Execute("(New-Object Net.WebClient).GetType().Name")); }