public void IFRS_Test_GetNodesByElement() { TestTaxonomy_IFRS s = new TestTaxonomy_IFRS(); s.CurrentLabelRole = "label"; s.CurrentLanguage = "en"; s.Load( IFRS_FILE); int errors = 0; s.Parse( out errors ); ArrayList nodeList = s.GetNodesByElement(); Assert.IsNotNull( nodeList ); Assert.AreEqual( 2591, nodeList.Count ); Console.WriteLine( "Nodes By Element: " ); foreach (Node n in nodeList ) { Console.WriteLine( TestNode.ToXml( 0, n ) ); } }
public void IFRS_Test_VerifyTuples() { TestTaxonomy_IFRS s = new TestTaxonomy_IFRS(); s.CurrentLabelRole = "label"; s.CurrentLanguage = "en"; s.Load( IFRS_FILE); int errors = 0; s.Parse( out errors ); ArrayList nodeList = s.GetNodesByElement(); Assert.IsNotNull( nodeList ); Assert.AreEqual( 2586, nodeList.Count ); Console.WriteLine( "Found Tuple Nodes: " ); foreach (Node n in nodeList ) { RecurseVerifyTuples( n ); } }
public void IFRS_ElementTaxonomyLinks() { TestTaxonomy_IFRS s = new TestTaxonomy_IFRS(); int errors = 0; if ( s.Load( IFRS_FILE, out errors ) != true ) { Assert.Fail( (string)s.ErrorList[0]); } errors = 0; s.Parse( out errors ); s.currentLanguage = "en"; s.currentLabelRole = "label"; ArrayList nodes = s.GetNodesByElement(); Assert.AreEqual( 0, ((Node)nodes[0]).TaxonomyInfoId, "Taxonomy id not correct" ); TaxonomyItem ti = s.GetTaxonomyInfo( (Node)nodes[0] ); Assert.AreEqual( "http://xbrl.iasb.org/int/fr/ifrs/gp/2004-11-15", ti.WebLocation, "target namespace wrong" ); Assert.AreEqual( IFRS_FILE, ti.Location, "targetLocation wrong" ); }