예제 #1
0
 public void DirectoryChildElements()
 {
     string[] childElements = schema.GetChildElements("Directory");
     Assert.AreEqual(4, childElements.Length);
     Assert.Contains("Component", childElements);
     Assert.Contains("Directory", childElements);
     Assert.Contains("Merge", childElements);
     Assert.Contains("SymbolPath", childElements);
 }
        public void SetUpFixture()
        {
            base.InitFixture();
            childElementAllowedWhenNoItemSelected = new string[view.AllowedChildElements.Count];
            view.AllowedChildElements.CopyTo(childElementAllowedWhenNoItemSelected, 0);
            WixDirectoryElement rootDir          = editor.Document.GetRootDirectory();
            XmlElement          directoryElement = (XmlElement)rootDir.ChildNodes[0];

            view.SelectedElement = directoryElement;
            editor.SelectedElementChanged();
            childElementsAllowedWhenDirectoryElementSelected = view.AllowedChildElements;

            WixSchemaCompletion schema = new WixSchemaCompletion();

            expectedDirectoryChildElementNames = schema.GetChildElements(directoryElement.Name);
        }