public void ResolveResultContainsConsoleClass() { List <ICompletionEntry> items = GetCompletionItems(); IClass consoleClass = PythonCompletionItemsHelper.FindClassFromCollection("Console", items); Assert.IsNotNull(consoleClass); }
public void MockProjectContentSystemNamespaceContentsIncludesConsoleClass() { List <ICompletionEntry> items = projectContent.GetNamespaceContents("System"); IClass consoleClass = PythonCompletionItemsHelper.FindClassFromCollection("Console", items); Assert.IsNotNull(consoleClass); }
public void CompletionItemsContainsDateClass() { List <ICompletionEntry> items = resolveResult.GetCompletionData(projectContent); IClass c = PythonCompletionItemsHelper.FindClassFromCollection("datetime", items); Assert.IsNotNull(c); }
public void FindClassFromArrayReturnsExpectedClass() { DefaultClass c = CreateClass(); ArrayList items = new ArrayList(); items.Add(c); Assert.AreEqual(c, PythonCompletionItemsHelper.FindClassFromCollection("Test", items)); }
public void FindClassFromArrayReturnsExpectedNullForUnknownClassName() { DefaultClass c = CreateClass(); ArrayList items = new ArrayList(); items.Add(c); Assert.IsNull(PythonCompletionItemsHelper.FindClassFromCollection("unknown-class-name", items)); }