mirror of
https://github.com/EiffelSoftware/eiffel-org.git
synced 2025-12-07 23:32:42 +01:00
Added release 19.05.
git-svn-id: https://svn.eiffel.com/eiffel-org/trunk@2152 abb3cda0-5349-4a8f-a601-0c33ac3a8c38
This commit is contained in:
@@ -0,0 +1,114 @@
|
||||
[[Property:title|The AutoTest Interface]]
|
||||
[[Property:weight|0]]
|
||||
[[Property:uuid|6eec11df-9ea0-6834-d41b-a0c23b87c485]]
|
||||
[[Image:AutoTest interface annotated 01]]
|
||||
|
||||
|
||||
The AutoTest interface consists of four primary components:
|
||||
# The toolbar
|
||||
# The tests pane
|
||||
# The test filtering box
|
||||
# The tabbed creation and results reporting pane
|
||||
|
||||
==Toolbar==
|
||||
|
||||
The toolbar allows you to create new tests using the '''[[#The New Eiffel test wizard|New Eiffel test wizard]]''' and to run existing tests.
|
||||
|
||||
The '''Create new tests''' command ( [[Image:Create new tests]] ) invokes the '''New Eiffel test wizard'''.
|
||||
|
||||
The '''Run filtered tests''' command ( [[Image:debug-run-icon]] ) will, by default, run all tests that are visible in the Tests pane. Whether or not a test is visible depends upon any test [[#Filtering|filtering]] currently in effect. The '''Run filtered tests''' allows other options for running tests through its drop-down icon ( [[Image:toolbar-dropdown-icon]] ).
|
||||
|
||||
|
||||
[[Image:AutoTest run all drop down]]
|
||||
|
||||
|
||||
The '''Debug filtered tests''' command ( [[Image:AutoTest debug all icon]] ) functions in a similar manner to '''Run filtered tests''' with the exception that each test is paused at its starting point in the EiffelStudio debugger. '''Debug filtered tests''' has a drop-down icon providing the same options as '''Run filtered tests'''.
|
||||
|
||||
|
||||
[[Image:AutoTest debug all drop down]]
|
||||
|
||||
|
||||
The '''Stop all test related tasks''' command ( [[Image:debug-stop-icon]] ) will halt all tests which were started by the '''Run filtered tests''' or '''Debug filtered tests''' commands.
|
||||
|
||||
|
||||
==Tests==
|
||||
|
||||
The Tests pane presents tests in one or more expandable tree views. The structures of the trees depend upon the [[#Filtering|filter]] criteria that you have specified for organizing the view. For example, if you look at tests based on the test classes in which they exist (tag root "''class''"), the structure of the tree view(s) will reflect the clusters in which the test classes exist.
|
||||
|
||||
|
||||
[[Image:AutoTest interface test view class]]
|
||||
|
||||
|
||||
Likewise, if you look at tests based on their target classes (tag root "''covers''"), the structure of the display will be based on the target classes.
|
||||
|
||||
|
||||
[[Image:AutoTest interface test view covers]]
|
||||
|
||||
|
||||
Tests and test classes are pickable in the Tests pane.
|
||||
|
||||
|
||||
==Filtering==
|
||||
|
||||
The '''Filter''' box allows you to limit which tests are visible in the Tests pane (and, by consequence, the tests run when '''Run filtered tests''' is clicked) by entering filter text in the box and pressing the Enter key. Filter text can be a string of characters that is contained in a test class or test routine name, or it can be a [[Create a manual test#About Tags|tag]] or a portion of a tag hierarchy.
|
||||
|
||||
In fact, filter text fully supports [http://www.regular-expressions.info/ regular expressions], so you can craft more complex and precise filters. (You will notice below when the '''Results''' choice is selected from the Filter box drop-down, that the filter text used is the regular expression "<code lang="text">^result</code>".)
|
||||
|
||||
Clicking the '''Clear filter''' icon ( [[Image:general-reset-icon]] ) to the right of the filter box will clear any filter contents and enable the viewing of all tests. The Tests pane is depicted below after clicking the '''Clear filter''' icon and expanding some of the items:
|
||||
|
||||
|
||||
[[Image:AutoTest tests pane null filter]]
|
||||
|
||||
|
||||
The '''Filter''' box has a drop down icon on its right end. By default this icon provides views of the tests in the Tests pane based on tag criteria.
|
||||
|
||||
|
||||
[[Image:AutoTest filter drop down]]
|
||||
|
||||
|
||||
The criteria are associated with the roots of their respective tag trees. So for example, if '''Results''' is chosen the Tests pane shows tests grouped by their latest results.
|
||||
|
||||
|
||||
[[Image:AutoTest filter result]]
|
||||
|
||||
|
||||
{{note|The '''result''' tag hierarchy is, as you may have guessed, virtual and dynamic. A test falling into the '''fail''' subtree may later become part of the '''pass''' subtree without any change to the '''"testing:"''' notes in the test routine code, where tags are established. But for filtering purposes '''result''' tags work like other tags. }}
|
||||
|
||||
|
||||
If the '''fail''' subtree name were appended to the '''result''' filter, only the failed tests would be visible in the Tests pane:
|
||||
|
||||
|
||||
[[Image:AutoTest filter result fail]]
|
||||
|
||||
|
||||
If the filter text is a character string that occurs in a test name, test class name, or a tag path, tests with any match will be visible:
|
||||
|
||||
|
||||
[[Image:AutoTest filter withdraw]]
|
||||
|
||||
|
||||
==Results==
|
||||
|
||||
This pane supports a tabbed display that provides information about the creation and execution of tests.
|
||||
|
||||
After creation of one or more tests, the creation is logged under the '''Creation''' tab.
|
||||
|
||||
After execution, the tests executed and the status of those tests are shown in the '''Execution''' tab.
|
||||
|
||||
|
||||
[[Image:AutoTest interface results execution]]
|
||||
|
||||
|
||||
After executing a set of tests, the Testing pane of the Outputs tool shows a chronology of the executions and the results of the tests executed.
|
||||
|
||||
|
||||
[[Image:AutoTest testing pane execution results]]
|
||||
|
||||
|
||||
You can view more detail about a test's execution by clicking the '''Information''' icon ( [[Image:AutoTest information icon]] ) to the right of the test's entry in '''Results''' when the '''Execution''' tab is selected.
|
||||
|
||||
|
||||
[[Image:AutoTest test results details]]
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,99 @@
|
||||
[[Property:title|The Eiffel Test Wizard]]
|
||||
[[Property:weight|1]]
|
||||
[[Property:uuid|305a8288-cb6a-df2a-1515-e23138e21566]]
|
||||
==Introduction==
|
||||
|
||||
The '''New Eiffel test wizard''' creates new tests based on information entered by a developer on a series of wizard panes. Each of the three test types supported by AutoTest requires certain unique information. Therefore, there is a unique sequence of wizard panes corresponding to each test type, but you will notice that some of the same wizard panes are used in more than one sequence.
|
||||
|
||||
The '''New Eiffel test wizard''' is invoked by clicking the '''Create new test''' button ( [[Image:create new tests]] ) on the AutoTest interface toolbar. By default, clicking '''Create new test''' invokes the wizard sequence for a manual test. To choose a different type of test, click the triangle to the right of '''Create new test''' button and use the drop-down menu to select the specific test type you want.
|
||||
|
||||
|
||||
[[Image:AutoTest create new test]]
|
||||
|
||||
|
||||
Once you begin the process or creation of a new test, you will be shown the sequence of wizard panes. The wizard panes are ordered in such a way that the information most likely to change from the creation of one test to the next appears in the earliest panes. This means that if you need only to change information on the first wizard pane, and the information on later panes can remain as it was when you created a previous test, then you can click the '''Launch''' button directly from the first wizard pane. In this way, you avoid having to re-enter the information on the later panes.
|
||||
|
||||
|
||||
==The manual test wizard sequence==
|
||||
|
||||
|
||||
Creating manual tests will involve using the following wizard panes. For a guided tour of this process, see [[Create a manual test]].
|
||||
|
||||
|
||||
===The "Manual Test" pane===
|
||||
|
||||
|
||||
In this pane you provide a name for the new test that will be created. This name will be a feature name of the created test class. In this pane you can also indicate that the created class should include redefined versions of features <eiffel>on_prepare</eiffel> (called during preparation for test execution) and/or <eiffel>on_clean</eiffel> (called during clean-up after test execution).
|
||||
|
||||
|
||||
[[Image:AutoTest Manual Test pane]]
|
||||
|
||||
|
||||
===The "Tags" pane===
|
||||
|
||||
This pane gives you the ability to associate the new test with certain [[Create a manual test#About Tags|tags]].
|
||||
|
||||
|
||||
[[Image:AutoTest Tags pane]]
|
||||
|
||||
|
||||
To add a tag for a covered class and feature, or a predefined tag, such as '''run test serially''' or '''run test in private evaluator''' click on the appropriate link below the text entry boxes.
|
||||
|
||||
There is an entry box with an '''Add''' button to its right. Use it to create entries for a tag system that you have developed.
|
||||
|
||||
|
||||
===The "General" pane===
|
||||
|
||||
Here you provide a name for the class that is your new test set.
|
||||
|
||||
|
||||
[[Image:AutoTest General pane]]
|
||||
|
||||
|
||||
You can also choose where you would like your test classes to reside. By default, tests will be kept in a folder in your project's EIFGENs folder. This is an easy way to do things, but if you manually delete the EIFGENs folder, you'll delete your tests. In the screenshot above a new cluster called "tests" was created to house the test suite.
|
||||
|
||||
|
||||
|
||||
==The extracted test wizard sequence==
|
||||
|
||||
|
||||
The '''Extract tests from debugger''' choice in the '''Create new test''' drop-down menu is only sensitive if the system is currently running.
|
||||
|
||||
Creating extracted tests will involve using the "Test Extraction", "Tags", and "General" wizard panes. The "Tags" and "General" panes are used as shown above.
|
||||
|
||||
|
||||
===The "Test Extraction" pane===
|
||||
|
||||
|
||||
[[Image:AutoTest Test Extraction Pane]]
|
||||
|
||||
|
||||
This pane provides a depiction of the current call stack. Choose the routine or routines for which you want extracted tests to be created.
|
||||
|
||||
|
||||
==The generated test wizard sequence==
|
||||
|
||||
For generated tests, there are two options on the '''Create new test''' drop-down menu. '''Generate tests for open classes''' and '''Generate tests for custom types'''. The difference is that if you select '''Generate tests for open classes''', AutoTest automatically populates the '''Types to test''' box with the names of any classes that are currently open in the Editor pane.
|
||||
|
||||
Creating generated tests will involve using "Test Generation", "Tags", and "General" panes. The "Tags" and "General" panes are used as shown above.
|
||||
|
||||
|
||||
===The "Test Generation" pane===
|
||||
|
||||
|
||||
[[Image:AutoTest Test Generation pane]]
|
||||
|
||||
|
||||
On this pane enter the information needed to produce generated tests. Use the '''Class or type name''' entry box, along with the <code>+</code> and <code>-</code> buttons, to declare a list of one or more classes as target classes for generated tests.
|
||||
|
||||
Other information necessary for creating generated tests is:
|
||||
|
||||
*'''Cutoff (minutes)''' -- How long AutoTest will execute random invocations of the routines in the classes to be tested, specified in minutes.
|
||||
*'''Cutoff (invocations)''' -- How long AutoTest will execute random invocations of the routines in the classes to be tested, specified by invocation count.
|
||||
*'''Routine timeout (seconds)''' -- How long AutoTest will wait for completion of any invocation.
|
||||
*'''Random number generation seed''' -- The seed used for random number generator used during the process. A value of zero instructs AutoTest to use a seed derived from the system clock.
|
||||
*'''Slice minimization''' -- Designate '''slicing''' as the approach for minimizing the size of generated tests.
|
||||
*'''DDMin for minimization''' -- Designate '''DDMin''' as the approach for minimizing the size of generated tests.
|
||||
*'''HTML statistics''' -- Output history and statistics from the synthesizing process in html format.
|
||||
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
[[Property:title|AutoTest]]
|
||||
[[Property:weight|-1]]
|
||||
[[Property:uuid|1d8cc843-238e-feaa-cfa6-629f080ffba7]]
|
||||
==Introduction==
|
||||
|
||||
AutoTest is a facility within EiffelStudio that helps developers create, manage, and execute software tests.
|
||||
|
||||
This documentation is intended to describe the AutoTest interface and capabilities. In addition to this material, you will find a tutorial entitled [[Using AutoTest]] in [[Introducing EiffelStudio]]. The tutorial employs a simple example that is used to work step-by-step through AutoTest's different facilities. The tutorial also explains testing basics and recommendations for using AutoTest. Lastly, the tutorial contains definitions for terminology used in both the tutorial and in these reference pages. It is recommended that you become familiar with these definitions, specifically:
|
||||
|
||||
#[[Testing: Background and basics#Test classes and tests|Test classes and tests]]
|
||||
#[[Testing: Background and basics#Types of tests|The types of test supported by AutoTest]]
|
||||
#[[Testing: Background and basics#Anatomy of a test|Target classes and target routines]]
|
||||
#[[Execute tests#About test results|Test results]]
|
||||
|
||||
|
||||
|
||||
==Components==
|
||||
|
||||
When you use AutoTest, you control things by using two components: '''[[The AutoTest Interface]]''' and '''[[The Eiffel Test Wizard]]'''. The interface is used to access, manage, execute, and monitor tests. The New Eiffel test wizard is used to help you create new tests.
|
||||
|
||||
|
||||
{{Caution|At this time, AutoTest will work only for project targets in the classic Eiffel environment. This means that projects targeted to Microsoft .Net will not be able to use AutoTest.}}
|
||||
|
||||
|
||||
{{Recommended|During the transition to void-safe Eiffel, projects can be built using '''experimental''' mode. This mode is as stable as '''non-experimental''' mode, but includes some facilities that might break existing code in a few circumstances. However, since version 6.5, EiffelStudio itself is built in experimental mode, so '''we recommend that you use AutoTest only on projects also built using experimental mode'''. Experimental mode can be invoked by using the "-experiment" option from the command line, or on Microsoft Windows by following the '''Start''' menu path to EiffelStudio and selecting experimental mode. }}
|
||||
|
||||
|
||||
{{SeeAlso|<br/>[[Using AutoTest]] }}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user