Tango (description language)

from Wikipedia, the free encyclopedia

Tango is a description language for describing software and its user interface from the user's point of view. To be discribed

  • static properties, e.g. B. this window consists of the following five control elements: ...
  • dynamic properties, e.g. B. when pressing this button the following happens: ...

The Tango specification only contains information about the reactions of the application, not about its implementation.

origin

The first documented use was around 1989 in an acceptance test analysis (ATA) as an upstream document for the creation of test specifications (ATS) and test procedures (ATP) according to the digital project methodology DPM of the Digital Equipment Corporation . The ATA is a strongly networked SGML document made up of lists and tables with which the status transitions of the application are described.

A text version of this description method has existed since approx. 1994, which can be created without the use of complex SGML editors such as VaxDocument and LSE. Since then, this description has been known as Tango (test analysis notation for graphical surfaces).

For a long time, the specification language was not documented in a binding manner, and there is a lack of suitable tools that could efficiently manage the highly networked specification. These are probably reasons for the low use of the description method.

In 2005, the syntax and the description methodology were fully described for the first time. The specification language was largely revised to version Tango 1.5. Compared to earlier versions, the description is much more formalized.

application

The SGML version could only be used to write down state transitions. The benefit lay in the reduction of the description complexity through the consideration of functional levels building on one another in the system to be described, similar to the OSI layer model for the description of communication processes. The operating elements of a system were determined by evaluating the state transitions, whereby the static relationship between the elements played no role and could therefore not be described directly.

The various text versions were used extensively to describe processes, especially application scenarios and test procedures. These Tango descriptions are generally not very formalized and essentially only use the opportunity to efficiently depict cause-effect relationships and the detailing of individual steps.

The text versions were used sporadically to specify systems on a technical level. The lack of suitable tools limits the scope of the description, so that the level of detail has been reduced or only subsystems have been described.

example

The application of Tango 1.5 is demonstrated using a related example. In the following, the first steps of a Linux installation from CD are used to show how dynamic and static properties of an application are described.

This example includes most of the common Tango language constructs. This is not a comprehensive introduction; it demonstrates how to read a Tango specification in principle.

Basic structure

A Tango specification describes aspects of a system and how they are interrelated. Every statement about the system is called an aspect . The specification consists of an unordered collection of aspects, each in a definition block . Each of these aspects can then be described or detailed by additional aspects in the definition block.

The example specification consists of definition blocks , introduced with the exclamation mark ! .

These blocks describe the installation process:

  !+LinuxInstallation
      …

some states of the pc

  !$PC
      …

and three windows

  !#WnSpracheWählen
      …
  !#WnGrundeinstellungen
      …
  !#WnLinuxInstallieren
      …

Detailing by indenting

An aspect in a line is described more precisely by additional aspects in the following lines that are indented compared to the superordinate aspect. The subordinate aspects are usually introduced with a period.

  !#WnSpracheWählen
      .TxWillkommenBeiYast2
      .TxAnleitung
      …

Description of operations

The Linux installation process comprises three steps in the given order:

  !+LinuxInstallation
      =>  - {CD einlegen, Rechner starten}
          - {warten bis der erste Bildschirm erscheint}
          - *WnSpracheWählen.OPEN

It is also described that the keyboard layout is initially set to "English".

          .PC.Tastaturlayout := "Englisch"

This initial value is not a separate step, but general information in this process, and is therefore noted with an introductory period, while the individual steps of the process are marked with the minus sign.

Description of static structures

The WnSspracheW Select window consists of two text passages TxWillkommenBeiYast2 and instructions TxAnleitung

  !#WnSpracheWählen
      .TxWillkommenBeiYast2
      .TxAnleitung

plus an unspecified control element with which a single language can be selected from a list

      .SsSprache

as well as two operable buttons that can be used to trigger system activities

      .+BtInstallationAbbrechen
      .+BtWeiter

The description of the dynamic properties begins with these two activators . Opening the window itself is also a process that is described as an additional activator

      .+OPEN

Description of dynamic properties

If a language is selected from the list in Sslanguage , i. H. the activator of a language in the list is triggered, then the visible selection in this list and the language of the text passages change

      .SsSprache
          ...+Sprache
              =>  .TxWillkommenBeiYast2.Sprache := {diese Sprache}
                  .TxAnleitung.Sprache := {diese Sprache}
                  .SsSprache.SELEKTION := {diese Sprache}

The installation can be canceled with the BtInstallationAbort button ; this process must be confirmed as a precaution. The installation process is only actually ended after confirmation by the USER . If the USER does not want this, the installation will continue.

      .+BtInstallationAbbrechen
          =>  ? USER << "Wirklich abbrechen?" =
                  = "Ja, abbrechen"
                      =>  .{Installation beendet}
                          .*WnSpracheWählen.CLOSE
                  = "Nein, weitermachen"
                      =>  .NICHTS_TUN

With the BtNext button , the current window WnSlanguageWähler is closed and the next window WnBasic Settings is opened.

      .+BtWeiter
          =>  .*WnSpracheWählen.CLOSE
              .*WnGrundeinstellungen.OPEN

Marking with special characters

The aspects of the description are marked according to their respective function:

  • the point .indicates an entry in an unordered list of elements or actions
  • the minus sign -indicates a step that must be completed before the next can begin
  • the garden fence #indicates a window of the application
  • the plus sign +indicates an activator that can be pressed to trigger an action
  • the dollar sign $indicates a status
  • the paragraph §character indicates a boundary condition or explanation
  • with =>the description of an action is initiated
  • the question mark introduces ?a query, the possible alternatives are marked with the = sign
  • Free-text descriptions are in braces {... }set
  • Values are in double quotation marks "... "set
  • Alternative values are in square brackets [... |... ]separated by a vertical bar
  • a comment extends from the introductory //to the end of the line
  • a repeatedly occurring element (a list ) is introduced by three leading points.

A list consists of several elements of the same type. The list elements are described by the following indented aspects. In the example, the list elements can be selected from the time zone list by clicking on them, this sets the time zone of the PC:

      .SsZeitzone
          ...+Zeitzone
              =>  .$PC.Zeitzone := {diese Zeitzone}

Marked with a specialization prefix

An aspect can be marked with a specialization prefix so that its function is easier to identify. These specialization prefixes are not part of the Tango syntax, they are freely definable and can be used to adapt the description to the respective subject.

The following prefixes are used to describe the software installation process in the example:

  • Windows are introduced with Wn(window),
  • pure display Txtext with (text),
  • editable text with Et(edit text) and
  • Buttons with Bt(button).
  • Radio buttons are Rbmarked with . A group of radio buttons is usually noted as a single element:
      .RbInstallation : [ "Neuinstallation" | "Update" ]
  • A list from which exactly one element can be selected is marked with Ss(select single). It is left open here whether this aspect is implemented by a list, a combo box, several radio buttons or in some other way.

Navigation with paths

A path identifies an aspect by noting the path from the topmost aspect of a definition block to the desired aspect. Each step is separated from the next by a point.

     WnSpracheWählen.TxAnleitung

The path does not have to start at the topmost aspect of a definition block, it just has to clearly identify the aspect. The name of the aspect alone is often sufficient as a path.

Complete example

 !+LinuxInstallation
      =>  .PC.Tastaturlayout := "Englisch"
          - {CD einlegen, Rechner starten}
          - {warten bis der erste Bildschirm erscheint}
          - *WnSpracheWählen.OPEN

  !$PC
      .$Tastaturlayout                      // aktuelle Tastenbelegung
      .$Zeitzone

  !#WnSpracheWählen
      .+OPEN
          =>  .?{erstmals angezeigt} = 
                  = "Ja, erstes Fenster"
                      =>  .TxWillkommenBeiYast2.Sprache := "Englisch"
                          .TxAnleitung.Sprache := "Englisch"
                  = "Nein, durch Zurück-Knopf geöffnet"
                      =>  .TxWillkommenBeiYast2.Sprache := {Sprache im letzten Fenster}
                          .TxAnleitung.Sprache := {Sprache im letzten Fenster}
      .TxWillkommenBeiYast2
      .TxAnleitung
      .SsSprache
          ...+Sprache
              =>  .TxWillkommenBeiYast2.Sprache := {diese Sprache}
                  .TxAnleitung.Sprache := {diese Sprache}
                  .SsSprache.SELEKTION := {diese Sprache}
      .+BtInstallationAbbrechen
          =>  ? USER << "Wirklich abbrechen?" =
                  = "Ja, abbrechen"
                      =>  .{Installation beendet}
                          .*WnSpracheWählen.CLOSE
                  = "Nein, weitermachen"
                      =>  .NICHTS_TUN
      .+BtWeiter
          =>  .*WnSpracheWählen.CLOSE
              .*WnGrundeinstellungen.OPEN


  !#WnGrundeinstellungen
      .+OPEN
          =>  .TxAnleitung.Sprache := {Sprache im letzten Fenster}
              .SsTastaturlayout := PC.Tastaturlayout
              .SsZeitzone := PC.Zeitzone
      .TxAnleitung
      .SsTastaturlayout
          ...+Tastaturlayout
              =>  .$PC.Tastaturlayout := {dieses Tastaturlayout}
      .SsZeitzone
          ...+Zeitzone
              =>  .$PC.Zeitzone := {diese Zeitzone}
      .EtTastaturtest
          .§{nur zum Ausprobieren, ohne Funktion}
      +BtZurück
          =>  .*WnSpracheWählen.OPEN
              .*WnGrundeinstellungen.CLOSE
      +BtInstallationAbbrechen
          =>  ? USER << "Wirklich abbrechen?" =
                  = "Ja, abbrechen"
                      =>  .{Installation wird beendet}
                          .*WnGrundeinstellungen.CLOSE
                  = "Nein, weitermachen"
                      =>  .NICHTS_TUN
      +BtWeiter
          =>  .*WnGrundeinstellungen.CLOSE
              .*WnLinuxInstallieren.OPEN


  !#WnLinuxInstallieren
      .+OPEN
          =>  .TxAnleitung.Sprache := {Sprache im letzten Fenster}
              .RbInstallation := "Neuinstallation"
      .TxAnleitung
      .RbInstallation : [ "Neuinstallation" | "Update" ]
      .+BtZurück
          =>  .*WnGrundeinstellungen.OPEN
              .*WnLinxInstallieren.CLOSE
      .+BtInstallationAbbrechen
          =>  ? USER << "Wirklich abbrechen?" =
                  = "Ja, abbrechen"
                      =>  .{Installation wird beendet}
                          .*WnLinuxInstallieren.CLOSE
                  = "Nein, weitermachen"
                      =>  .NICHTS_TUN
      +BtWeiter
          =>  ...

Final notes

This example shows that the user's point of view is decisive for the description, and not implementation aspects. This describes what the user sees regardless of whether, how and how complex this behavior is implemented:

  • The selected language is described as {language in last window} . An implementation-related description would have to consider where in the system this state is saved and updated in a variable.
  • The aspects are already known or postulated through their use, an explicit definition is not necessary. Therefore, the descriptive user can "invent" any aspect that he needs to describe the desired behavior.
  • Every aspect of the specification is visible and can be used anywhere by specifying the path.

There are no keywords in Tango, all language elements are represented by special characters. Specialization prefixes can be freely defined to adapt to a subject area.

Web links