Test Template Framework

The Test Template Framework (TTF) is a model-based testing (MBT) framework proposed by Phil Stocks and David Carrington in (Stocks & Carrington 1996) for the purpose of software testing. Although the TTF was meant to be notation-independent, the original presentation was made using the Z formal notation. It is one of the few MBT frameworks approaching unit testing.

Introduction

The TTF is a specific proposal of model-based testing (MBT). It considers models to be Z specifications. Each operation within the specification is analyzed to derive or generate abstract test cases. This analysis consists of the following steps:

  1. Define the input space (IS) of each operation.
  2. Derive the valid input space (VIS) from the IS of each operation.
  3. Apply one or more testing tactics,[1] starting from each VIS, to build a testing tree for each operation. Testing trees are populated with nodes called test classes.
  4. Prune each of the resulting testing trees.
  5. Find one or more abstract test cases from each leaf in each testing tree.

One of the main advantages of the TTF is that all of these concepts are expressed in the same notation of the specification, i.e. the Z notation. Hence, the engineer has to know only one notation to perform the analysis down to the generation of abstract test cases.

Important concepts

In this section the main concepts defined by the TTF are described.

Input space

Let be a Z operation. Let be all the input and (non-primed) state variables referenced in , and their corresponding types. The Input Space (IS) of , written , is the Z schema box defined by .

Valid input space

Let be a Z operation. Let be the precondition of . The Valid Input Space (VIS) of , written , is the Z schema box defined by .

Test class

Let be a Z operation and let be any predicate depending on one or more of the variables defined in . Then, the Z schema box is a test class of . Note that this schema is equivalent to . This observation can be generalized by saying that if is a test class of , then the Z schema box defined by is also a test class of . According to this definition the VIS is also a test class.

If is a test class of , then the predicate in is said to be the characteristic predicate of or is characterized by .

Test classes are also called test objectives (Utting & Legeard 2007), test templates (Stocks & Carrington 1996) and test specifications.

Testing tactic

In the context of the TTF a testing tactic[1] is a means to partition any test class of any operation. However, some of the testing tactics used in practice actually do not always generate a partition of some test classes.

Some testing tactics originally proposed for the TTF are the following:

  • Disjunctive Normal Form (DNF). By applying this tactic the operation is written in Disjunctive Normal Form and the test class is divided in as many test classes as terms are in the resulting operation's predicate. The predicate added to each new test class is the precondition of one of the terms in the operation's predicate.
  • Standard Partitions (SP). This tactic uses a predefined partition of some mathematical operator (Stocks 1993). For example, the following is a good partition for expressions of the form where is one of , and (see Set theory).
    As can be noticed, standard partitions might change according to how much testing the engineer wants to perform.
  • Sub-domain Propagation (SDP). This tactic is applied to expressions containing:
    1. Two or more mathematical operators for which there are already defined standard partitions, or
    2. Mathematical operators which are defined in terms of other mathematical operators.
    In any of these cases, the standard partitions of the operators appearing in the expression or in the definition of a complex one, are combined to produce a partition for the expression. If the tactic is applied to the second case, then the resulting partition can be considered as the standard partition for that operator. Stocks and Carrington in (Stocks & Carrington 1996) illustrate this situation with , where means domain anti-restriction, by giving standard partitions for and and propagating them to calculate a partition for .
  • Specification Mutation (SM). The first step of this tactic consists in generating a mutant of the Z operation. A mutant of a Z operation is similar in concept to a mutant of a program, i.e. it is a modified version of the operation. The modification is introduced by the engineer with the intention of uncovering an error in the implementation. The mutant should be the specification that the engineer guesses the programmer has implemented. Then, the engineer has to calculate the subset of the VIS that yields different results in both specifications. The predicate of this set is used to derive a new test class.

Some other testing tactics that may also be used are the following:

  • In Set Extension (ISE). It applies to predicates of the form . In this case, it generates n test classes such that a predicate of the form is added to each of them.
  • Mandatory Test Set (MTS). This tactic associates a set of constant values to a VIS' variable and generates as many test classes as elements are in the set. Each test class is characterized by a predicate of the form where var is the name of the variable and val is one of the values of the set.
  • Numeric Ranges (NR). This tactic applies only to VIS' variables of type (or its "subtype" ). It consists in associating a range to a variable and deriving test classes by comparing the variable with the limits of the range in some ways. More formally, let n be a variable of type and let be the associated range. Then, the tactic generates the test classes characterized by the following predicates: , , , , .
  • Free Type (FT). This tactic generates as many test classes as elements a free (enumerated) type has. In other words, if a model defines type COLOUR ::= red | blue | green and some operation uses c of type COLOUR, then by applying this tactic each test class will by divided into three new test classes: one in which c equals red, the other in which c equals blue, and the third where c equals green.
  • Proper Subset of Set Extension (PSSE). This tactic uses the same concept of ISE but applied to set inclusions. PSSE helps to test operations including predicates like . When PSSE is applied it generates test classes where a predicate of the form with and , is added to each class. is excluded from because expr is a proper subset of .
  • Subset of Set Extension (SSE). It is identical to PSSE but it applies to predicates of the form in which case it generates by considering also .

Testing tree&

The application of a testing tactic to the VIS generates some test classes. If some of these test classes are further partitioned by applying one or more testing tactics, a new set of test classes is obtained. This process can continue by applying testing tactics to the test classes generated so far. Evidently, the result of this process can be drawn as a tree with the VIS as the root node, the test classes generated by the first testing tactic as its children, and so on. Furthermore, Stocks and Carrington in (Stocks & Carrington 1996) propose to use the Z notation to build the tree, as follows.

Pruning testing trees

In general a test class' predicate is a conjunction of two or more predicates. It is likely, then, that some test classes are empty because their predicates are contradictions. These test classes must be pruned from the testing tree because they represent impossible combinations of input values, i.e. no abstract test case can be derived out of them.

Abstract test case

An abstract test case is an element belonging to a test class. The TTF prescribes that abstract test cases should be derived only from the leaves of the testing tree. Abstract test cases can also be written as Z schema boxes. Let be some operation, let be the VIS of , let be all the variables declared in , let be a (leaf) test class of the testing tree associated to , let be the characteristic predicates of each test class from up to (by following the edges from child to parent), and let be constant values satisfying . Then, an abstract test case of is the Z schema box defined by .

See also

References

  • Stocks, Phil; Carrington, David (1996), "A framework for specification-based testing", IEEE Transactions on Software Engineering, 22 (11): 777–793, doi:10.1109/32.553698.
  • Utting, Mark; Legeard, Bruno (2007), Practical Model-Based Testing: A Tools Approach (1st ed.), Morgan Kaufmann, ISBN 0-12-372501-1.
  • Stocks, Phil (1993), Applying Formal Methods to Software Testing, Department of Computer Science, University of Queensland, PhD thesis.

Notes

  1. ^ a b Stocks and Carrington use the term testing strategies in (Stocks & Carrington 1996).

Read other articles:

Mustafa ChamranLahir2 Oktober 1932Teheran, IranMeninggal21 Juni 1981(1981-06-21) (umur 49)Dehlaviyeh, IranPengabdian IranDinas/cabangAngkatan Bersenjata IranLama dinas1975–1981PangkatMenteri PertahananPerang/pertempuranPerang Saudara LebanonPerang Iran-Irak Mustafa Chamran Savei (1932 – 21 Juni 1981) adalah Menteri Pertahanan Iran dan anggota Majelis, sekaligus juga sebagai komandan dari sukarelawan paramiliter pada Perang Iran-Irak. Ilmuwan Ia adalah seorang Ilmuwan Iran. ...

 

Caetra en el reverso de un dupondio de la ceca del Noroeste Las acuñaciones conocidas como moneta castrensis o de caetra, forman parte de las emisiones o acuñaciones de la ceca del noroeste de la península ibérica.[1]​ Estas acuñaciones carecen de topónimo, por lo que desconocemos su procedencia exacta. Ni indica si fue acuñada por orden de un magistrado romano, por lo que es muy probable, que su acuñación sea de época imperial. Cronología Denario de Augusto acuñado por Publ...

 

American Music Awards (AMAs) adalah acara penghargaan musik tahunan Amerika, umumnya diadakan pada musim gugur, dibentuk oleh Dick Clark pada tahun 1973 untuk ABC ketika kontrak jaringan untuk menayangkan Grammy Awards berakhir.Dari tahun 1973 hingga 2005, baik pemenang maupun nominasi dipilih oleh anggota industri musik, berdasarkan kinerja komersial, seperti penjualan dan pemutaran. Sejak tahun 2006, pemenang telah ditentukan oleh jajak pendapat publik dan penggemar, yang dapat memilih mela...

Untuk tempat lain yang bernama sama, lihat Ciherang. CiherangDesaNegara IndonesiaProvinsiJawa BaratKabupatenSumedangKecamatanSumedang SelatanKode Kemendagri32.11.17.2012 Luas... km²Jumlah penduduk... jiwaKepadatan... jiwa/km² Jalan dari Ciherang ke Sumedang (1910-1930) Ciherang adalah desa di kecamatan Sumedang Selatan, Sumedang, Jawa Barat, Indonesia. Pranala luar (Indonesia) Keputusan Menteri Dalam Negeri Nomor 050-145 Tahun 2022 tentang Pemberian dan Pemutakhiran Kode, Data Wilayah ...

 

Bagian dari seriAkidah Rukun Islam Syahadat Salat Saum Zakat Haji SunniRukun iman Allah Nabi dan Rasul Kitab-kitab Allah Malaikat Hari akhir Qada dan Qadar Mazhab teologi Islam Atsariyah Hambali1 Ahli Hadis Ilmu kalam Asy'ariyah Maliki Syafi'i Maturidiyah Hanafi SyiahTeologi Dua Belas Imam4 Tauhid Adalah Kenabian Imamah Hari akhir Rukun Islam Salat Saum Zakat Haji Khums Jihad Amar makruf Nahi mungkar Tawalli Tabarri Tujuh rukun Ismailiyah5 al-Wilayah Tauhid Salat Zakat Saum Haji Jihad Konsep ...

 

Austroasiatic group in Northern Vietnam Part of a series on the History of Vietnam Prehistoric Paleolithic Sơn Vi culture 20,000 BC–12,000 BC Mesolithic Hoabinhian 12,000 BC–10,000 BC Neolithic Bắc Sơn culture 10,000 BC–8,000 BC Quỳnh Văn culture 8,000 BC–6,000 BC Đa Bút culture 4,000 BC–3,000 BC Ancient Hồng Bàng dynasty 2879 BC–258 BC Thục dynasty 257 BC–179 BC Triệu dynasty 204 BC–111 BC Dominated 1st Chinese domination 111 BC–40 AD Trung sisters' rebellio...

Diagrama de patente Snurfer (US 3378274) El Snurfer fue el predecesor del snowboard . Era un monoesquí, que se montaba como una tabla de snowboard, pero al igual que un monopatín o una tabla de surf, no tenía fijaciones. Según la patente de 1966[1]​ del inventor Sherman Poppen, era más ancho y más corto que un par de esquís, con un reposapiés antideslizante. Al igual que un trineo, tenía un cordón sujeto al frente. Historia Sherman Poppen creó originalmente el dispositivo el ...

 

US Army military airport located on the Fort Bliss military base in El Paso, TX Biggs Army AirfieldUSGS 1996 photo of Biggs Army AirfieldIATA: BIFICAO: KBIFFAA LID: BIFSummaryAirport typeMilitaryOwner United States ArmyLocationFort Bliss, El Paso, TexasBuilt1916In use1916–presentElevation AMSL3,946 ft / 1,203 mCoordinates31°50′56″N 106°22′01″W / 31.849°N 106.367°W / 31.849; -106.367Runways Direction Length Surface ft m 4/22 13,554 4,131 Asp...

 

Probability that random variable X is less than or equal to x This article needs additional citations for verification. Please help improve this article by adding citations to reliable sources. Unsourced material may be challenged and removed.Find sources: Cumulative distribution function – news · newspapers · books · scholar · JSTOR (March 2010) (Learn how and when to remove this template message) Cumulative distribution function for the exponential d...

Jasaw Chan K'awiil IAjaw TikalPrasasti 16, didirikan pada 711 mewakili Jasaw Chan K'awiil I.BerkuasaMay 3, 682-734PendahuluNuun Ujol ChaakPenerusYik'in Chan K'awiilKelahiransebelum 682Kematian734PemakamanKuil 1 (Makam 116)AyahNuun Ujol ChaakIbuPermaisuri Tahta JaguarAnakYik'in Chan K'awiilAgamaAgama Maya Jasaw Chan K'awiil I juga disebut sebagai Penguasa A, Ah Cacao dan Langit Hujan, (sebelum 682-734), adalah seorang ajaw dari kota Maya Tikal. Ia naik tahta pada 3 Mei 682 dan memerintah sampa...

 

1923 silent film by Robert Z. Leonard Fashion RowDirected byRobert Z. LeonardWritten byAlfred A. CohnSada CowanHoward HigginProduced byRobert Z. LeonardStarringMae MurrayEarle FoxeFreeman WoodCinematographyOliver T. MarshProductioncompanyTiffany PicturesDistributed byMetro PicturesRelease date December 3, 1923 (1923-12-03) Running time70 minutesCountryUnited StatesLanguageSilent (English intertitles) Fashion Row is a 1923 American silent drama film directed by Robert Z. Leonard...

 

Оборона північно-східної України Друга радянсько-українська війна Дата: 11 листопада 1918[1] - лютий 1919 Місце: Чернігівська, Харківська, Полтавська губернії. Результат: Сторони Українська Держава Радянська Росія Командувачі Павло Скоропадський Винниченко Володимир Кир...

French-American animated television series Dragon FlyzGenreAdventure-adventureDramaFantasyScience fictionCreated byJohn GentileAnthony GentileSavin Yeatman-EiffelDeveloped bySavin Yeatman-EiffelDirected byGuillaume Ivernel (art)Xavier GiacomettiVoices ofT. J. BenjaminSaul BernsteinThomas CannizzaroDonna DaleyJohnathan DavisDon MayoJames MichaelK. C. NoelJimmy UncleTheme music composerJohn CarneyComposerDavid FriedmanCountry of originFranceUnited StatesOriginal languageEnglishNo. of seasons1No...

 

2006 studio album by Mondo Generator This article is about the album by Nick Oliveri and the Mondo Generator. For the Doctor Who serial or episode sometimes called The Dead Planet, see The Daleks. Not to be confused with Dead Plane. Dead Planet: SonicSlowMotionTrailsStudio album by Nick Oliveri and the Mondo GeneratorReleasedSeptember 4, 2006 (2006-09-04)Length42:16LabelMother Tongue (UK/Europe)Impedance (Australia)ProducerNick OliveriNick RaskulineczMathias SchneebergerDea...

 

Yohanes 7Yohanes 16:14-22 pada sisi recto dari Papirus 5, yang ditulis sekitar tahun 250 M.KitabInjil YohanesKategoriInjilBagian Alkitab KristenPerjanjian BaruUrutan dalamKitab Kristen4← pasal 6 pasal 8 → Yohanes 7 (disingkat Yoh 7) adalah pasal ketujuh Injil Yohanes pada Perjanjian Baru dalam Alkitab Kristen, menurut kesaksian Yohanes, seorang dari Keduabelas Rasul pertama Yesus Kristus.[1][2] Teks Naskah aslinya ditulis dalam bahasa Yunani. Sejumlah naskah kuno t...

Указ «Защита нации от въезда иностранных террористов в Соединённые Штаты»англ. Executive Order «Protecting the Nation from Foreign Terrorist Entry into the United States» Д. Трамп подписывает Указ «Защита нации от въезда иностранных террористов в Соединённые Штаты» Вид Правительственное распоряжение Госу...

 

Chemical compound NalodeineClinical dataOther namesN-AllylnorcodeineIdentifiers IUPAC name (4R,4aR,7S,7aR,12bS)-9-methoxy-3-prop-2-enyl-2,4,4a,7,7a,13-hexahydro-1H-4,12-methanobenzofuro[3,2-e]isoquinoline-7-ol CAS Number56195-50-7 YPubChem CID5486632ChemSpider4588998UNIIYD9M6BEL6SChemical and physical dataFormulaC20H23NO3Molar mass325.408 g·mol−13D model (JSmol)Interactive image SMILES COC1=C2C3=C(CC4C5C3(CCN4CC=C)C(O2)C(C=C5)O)C=C1 InChI InChI=1S/C20H23NO3/c1-3-9-21-10-8-20-13-5...

 

For other uses, see Romance of the Western Chamber (disambiguation). A scene from Min Qiji's multi-colored woodblock printing album depicting scenes from the play Romance of the Western Chamber (traditional Chinese: 西廂記; simplified Chinese: 西厢记; pinyin: Xīxiāng Jì; Wade–Giles: Hsi-hsiang-chi), also translated as The Story of the Western Wing, The West Chamber, Romance of the Western Bower and similar titles, is one of the most famous Chinese dramatic works. It...

В этой статье недостаточно критики, так как необходимо освещение с различных точек зрения. Статью нельзя назвать рекламной, но в ней слабо представлена критика. Пожалуйста, добавьте информацию из публикаций и других источников, позволяющих осветить объект статьи с разн...

 

American record producer (1906–1968) Eric Bernay (March 25, 1906 – November 2, 1968) was an American record producer, best known for founding Keynote Records. Early life Eric Bernay (né Bernstein) was born in Odessa, Ukraine, which was then part of the Russian Empire; he came to the United States as an infant.[1] Keynote years He started Keynote Records in 1937;[1] previously he had been the owner of a mid-town Manhattan record store, The Music Room. His primary interest ...

 

Strategi Solo vs Squad di Free Fire: Cara Menang Mudah!