TCML – an XML-Based Test Case Format
Total Page:16
File Type:pdf, Size:1020Kb
TCML – An XML-Based Test Case Format Mohd Farid Jaafar, Mohd Hasan Selamat, Abdul Azim Abdul Ghani Faculty of Computer Science and Information Technology University Putra Malaysia 43400 UPM Serdang Selangor, MALAYSIA {mfarid, hasan, azim}@fsktm.upm.edu.my Abstract - Testing is important and gives the confident software [2, 3]. This cost is just for a normal to the developer and user; but it is expensive and may application but if it involves extreme and critical consume at least 50% of the total costs involved in software, the number might increases. The main developing software. This cost is just for a normal concern in testing is the effectiveness of finding an application but if it involves extreme and critical error. If it doesn’t find any error, it can be considered software, the number might increases. As we know, designing test suite for testing is a tedious and as failed. This can be avoided by careful design of meticulous work. We need to have a deep test case and good selection of test suite. understanding of the program before we could design a good test suite and even an expert tends to miss some Most studies in designing test cases are using test cases. Manual testing for large-scale program is requirement specification, complex technique i.e. Z very expensive and frustrating for humans. The same and third-party tools that require novices and non- scenario applies in Visual Programming Language expert user to supply information that are not (VPL). Visual Programming (VP) is a much complex familiar to them. It is certain that what they supplied program than conventional one. Testing VP program might be inaccurate and thus affects the test suite give users the confidence on what they visualize is correctly transformed according to their perception. produced. Furthermore, there are no standard Most studies in designing test suites are using structures in exchanging the data about a program. requirement specification, complex technique (i.e. Z) and third-party tools that require novices and non- 2. XML expert user to supply information that is not familiar to them. It is certain that the information they supplied is The eXtensible Markup Language (XML) is an more or less inaccurate and thus affects the test suite industry-standard format for representing structured produced. Furthermore, there are no standard documents, storing and transferring data. Data stored structures in exchanging the data about a program. in XML is all text, identified by tags, similar to The objective of this paper is to propose an XML-based test case language called Test Case Markup Language HTML tags. The tags in XML are not predefined as (TCML). they are in HTML. The tags can identify fields by name. In addition to an XML file, there are also 1. INTRODUCTION XML schema file. The schema describes the fields, data types, and any constraints, such as required Testing is a process of examining the functionality fields. The schema is also defined with XML tags. and correctness of a program by running it with a The format of XML data offers several advantages certain condition. It is also known as any activity for programming [5]. Some of XML most important aimed at evaluating an attribute or capability of a features are: program or system and determining that it meets its required results. Simplicity. Structure information obtained by named opening and closing tags. As a text format, XML can Software testing is a process used to identify the be easily read, produced, and transmitted. correctness, completeness and quality of the developed software. It is an important process in Generality. From its general structure any desirable supporting quality assurance [1, 2] and represents the data format can be instantiated. ultimate review of specification, design and coding [3]. It impacts all phases of the development, Standardization. The XML standard is developed including the requirements and specifications and controlled by the World Wide Web Consortium. preparation [4]. Testing usually performs for one or Many large and important companies are supporting two reasons: (1) defect detection, and (2) reliability XML. estimation. Altogether, these characteristics make XML a first Testing is important and give confidence to the choice data format for data exchange and developer and user; it is expensive and may consume representing data. Many applications for XML have at least 50% of the total costs involved in developing 1-42440220-4/$20.00 © 2006 IEEE. 1 been created for structuring data in various fields enables applications to extend the standard GraphML includes: vocabulary by custom data labels that are transparent to other applications not aware of the extension. • Mathematics (MathML), With the use of XML syntax, GraphML can be used • Chemistry (CML), in combination with other XML based formats. • Speech (SpeechML) and GraphML uses a SQL-like language mainly extended • Financial Report (XFRML). by path expressions. There exist quite a few graph languages for XML by Furthermore, applications are free to ignore unknown now. The flavor of formulating graph differs, though, concepts appearing in the structural layer, such as and there are also differences in their expressiveness. <port>s, <hyperedge>s or nested <graph>s. They are There have been number of research on graph even powerful enough to specify advanced representation using XML, among them are transformations that go beyond mapping XML GraphXML, GraphML, XGMML and GXL. elements directly to other XML elements or other simple text units. However, advanced 2.1 GraphXML transformations may result in long-winded style sheets that are intricate to maintain, and most likely GraphXML is a graph description language in XML to be inefficient. Extension functions appear to be the that can be used as an interchange format for graph natural way out of such difficulties. We found that, drawing and visualization packages. The generality as rule-of-thumb, XSLT should be used primarily to and rich features of XML make it possible to define do the structural parts of a transformation, such as an interchange format that not only supports the creating new elements or attributes, whereas pure, mathematical description of a graph, but also specialized extensions are better for complex the needs of information visualization applications computations that are difficult to express or that view graph-based data structures. A list of inefficient to run using pure XSLT. features supported by GraphXML includes: embedded and hyperlinked data references, 2.3 XGMML hierarchical (nested) graphs, graph metadata such as graph theoretic properties, presentation styles such as XGMML (eXtensible Graph Markup and Modeling color and geometry, and edit actions for graph Language) is an XML application based on GML, transformations and history capture. which is used for graph description. XGMML uses tags to describe nodes and edges of a graph. The The goal of GraphXML is to provide a general purpose of XGMML is to make possible the interchange format for graph drawing and exchange of graphs between different authoring and visualization systems, and to connect those systems browsing tools for graphs. The conversion of graphs to other applications. What we are trying here is to written in GML to XGMML is trivial. Using XSL map the source code of the VPL using graph. The with XGMML allows the translation of graphs to requirements of information visualization have different formats. XGMML was created to be use for greatly influenced design decisions during the the WWWPAL System that visualizes web sites as a development of GraphXML. Although GraphXML graph. Web Robots can navigate through a web site can be used for the description of purely and save the graph information as an XGMML file. mathematical graphs, restricted to the set of nodes XGMML, as any other XML application, can be and edges, information visualization applications mixed with other markup languages to describe require more features. The simplicity of GraphXML additional graph, node and/or edge information. is great but when in come to the complex source code, it seems complex and not suitable for test case An XGMML document describes a graph structure. representation. Furthermore, we do not care about The root element is graph and it can contain node, the visual appearance of the graphs, such as the color edge and att elements. The node element describes a of the edges, images used in a window containing a node of a graph and the edge element describes an specific graph, only the value and operation of the edge of a graph. Additional information for graphs, node. nodes and edges can be attached using the att element. A graph element can be contained in an att 2.2 GraphML element and this graph will be considered as sub graph of the main graph. The graphics element can GraphML (Graph Markup Language) is an XML- be included in a node or edge element, and it based format for the description of graph structures, describes the graphic representation either of a node designed to improve tool interoperability and reduce or an edge. communication overhead [6]. A key feature of GraphML is the separation into structural and data XGMML documents can be validated against the layer, both conceptually and syntactically; this DTD, xgmml.dtd. XGMML well formed documents 2 can be part of other XML documents. XGMML is <graph> based on Graph Modeling Language (GML), but <node key="id1" type="2"> uses XML to express the information rather than the … text format used by GML. Because XGMML is an </node> XML application, it can take advantage of XML <edge source="id5" target="id2"/> tools, notably XSLT. XGMML is useful for general </graph> graphing functionality and it can be used for Web site mapping as well. XGMML can also be used to Fig.