2. The Zanebug GUI

The Zanebug GUI is a feature-rich user interface. This section will walk you through the numerous options it provides.

2.1. Color Code

Various parts of the Zanebug GUI utilize a simple color-coding system to display the result of a Test:

Table 1. Color Coding for Tests

GreenPassed
YellowIgnored
RedFailed

This color-coding applies to all levels of testing.

2.2. File Menu

Figure 1. File Menu

File Menu

The File Menu provides the following options:

  • File

    • Add Assembly (Ctrl+A)

      Provides a file dialog to locate an assembly. As long as the assembly contains NUnit or Zanebug TestFixtures, it will load the tests and display them in the TestSuite tree

    • Add VS.NET Project (Ctrl+V)

      Provides a file dialog to locate a VS.NET project file. As long as the project output contains NUnit or Zanebug TestFixtures, it will load the tests and display them in the TestSuite tree

    • Remove Assembly

      Removes the selected assembly from the TestSuite tree

    • Reload (Ctrl+L)

      Reloads all assemblies

      Note

      Normally, the Zanebug engine will automatically reload assemblies when they change. If for some reason this doesn't happen, use this to manually reload the assemblies

    • Open Zanebug File (Ctrl+O)

      Opens the specified .zanebug file, and loads all assemblies listed within it

    • Save Zanebug File (Ctrl+S)

      Saves the the list of all currently loaded assemblies to a .zanebug file for later retrieval

  • Mode (Ctrl+M)

    Mode switches between the following two modes:

    • Developer Mode

      Developer mode will shrink the Zanebug GUI to only display the Test Bar, and place the GUI as always on top. This allows developers to easily run tests while developing in VS.NET, etc. without having to constantly switch between apps.

    • Tester Mode

      This is the default mode.

  • Test

    • Run (Ctrl+R)

      Runs all tests

    • Stop (Ctrl+Shift+S)

      Stops all tests

  • Options

    • Verbose Mode

      Displays the name of the currently running test above any console output. For example:

      ==================================================
      TEST: SomeTest
      ==================================================
      Some output

      If Verbose Mode is not checked, then only "Some output" would appear

    • Verbose Setup / Teardown

      Displays the name of the SetUp or TearDown method when it runs. For example:

      ==================================================
      TEST: SomeTest
      ==================================================
      ***** SomeTestSetUp
      Some output
      ***** SomeTestTearDown
      

      This allows you to ensure that the correct SetUp and TearDown methods are running, along with diagnosing where they occur in the process

  • Reports

    • Save to Text

      Saves the TestSuite results to formatted text.

    • Save to Xml

      Saves the TestSuite results to XML format

      Note

      There is currently no XSLT transformation for the outputed XML. This will be addressed in the next release

  • Help

    • Online Documentation

      Takes you to the online documenation

    • Product Website

      Takes you to the Zanebug homepage

    • Support

      Displays support contact information

2.3. Test Bar

Figure 2. Test Bar

Test Bar

The Test Bar allows you to start and stop tests, and displays the current progress:

  • Run

    Starts running the TestSuite.

  • Stop

    Stops running the TestSuite

    Note

    If the TestSuite is aborted (i.e. stopped), the results tabs (All / Failed / Passed / Ignored) will not be populated.

  • Currently Running Test

    The name of the currently running Test is displayed in red below the Run / Stop buttons

  • Overall Progress

    Displays the overall progress of the TestSuite. The first number ( 1 / 2 ) is the number of Tests that have been run. The second number ( 1 / 2 ) is the total number of Tests that will be run.

    A red bar means that at least one Test has failed, so the overall TestSuite has failed. A green bar means no Tests have failed.

  • Assembly Iteration

    Displays the number of times that the TestSuite will be run, and the total number of times it has run. Example: 1/2 --> The TestSuite has completed 1 of 2 iterations.

  • Fixture Iteration

    Displays the number of times that the TestFixture will be run, and the total number of times it has run. Example: 1/2 --> The TestFixture has completed 1 of 2 iterations.

  • Test Iteration

    Displays the number of times that the Test will be run, and the total number of times it has run. Example: 1/2 --> The Test has completed 1 of 2 iterations.

2.4. Summary Tab

Figure 3. Summary Tab

Summary Tab

The Summary Tab is composed of three content blocks:

  • TestSuite TreeView

    The TreeView lists the tree structure of the TestSuite, TestAssemblies, TestFixtures and Tests. As a TestSuite runs, these various levels will be continually updated to display the current results.

    All checked items will be run. All unchecked items will be ignored.

  • Summary Groupbox

    The Summary Groupbox displays the overall results in two ways. First, it displays the number of tests that have passed and/or failed. Secondly, it displays a statistic of the % passed. This is a useful statistic to track over time.

  • Run-Time Editor Groupbox

    The Run-Time Editor groupbox allows you to change the properties of test items at run-time. For example, you can adjust the number of times that a Test should run, the Category it should display under, etc. This allows you to set specific values at design-time, but edit them at run-time rather than changing and recompiling.

    Depending on the tree node selected, you'll see different options.

    Important

    The Exception box allows you to enter an ExpectedException. You must enter the full class name, to include namespace. Example: System.Exception. If you just enter Exception, Zanebug will throw an error. To remove an ExpectedException, simply delete all text from the box.

2.5. Formatted Results

The Formatted Results tab lists all content in a well-formatted block of text. This allows for quick scanning of all results, to include test summaries.

2.6. Result Tabs (All / Passed / Failed / Ignored)

Figure 4. All Tab

All Tab

2.6.1. Overview of Tabs

The results tabs provide comprehensive information on test execution. The results are separated into 4 distinct tabs:

  • All

    All displays all test results, regardless of whether they're for passed, failed or ignored tests. This provides a great way to do side-by-side comparisons of multiple result types.

  • Passed

    The Passed tab displays the results of all Test that have passed

  • Failed

    The Failed tab displays the results of all Tests that have failed

  • Ignored

    The Ignored tab displays the results of all Test that have been ignored

2.6.2. Explanation of Columns

The All / Passed / Failed tabs contain multiple columns. Below is a summary of each:

Table 2. Explanation of Columns for All / Passed / Failed tabs

Column NameDescription
FixtureThe name of the TestFixture that the Test belongs to
TestThe name of the Test
ResultAny result output. For example, if an exception is thrown, the exception message would be displayed here.
AvgThe average run time for the Test (measured in seconds). This is calculated by adding the duration of all Test iterations, and dividing it by the # of iterations (set with the Repeat attribute).
%The % of overall TestSuite execution time. This is calculated by adding the duration of all Tests, and dividing it by the duration of this Test
Ops/sThe number of times that this Test can be run in a second. This is calculated by dividing 1 second by the Test duration.
MemoryThe amount of memory consumed by the test. This is calculated by measuring the memory used for the TestSuite prior to the Test run, and substracting it from the memory used for the TestSuite after the Test run.

Warning

This is currently a beta feature, and should be used accordingly

DurationThe amount of time it takes for the Test to execute (measured in seconds).
ThreadThe thread # that the Test ran on.
AThe TestAssembly iterationthat the Test belongs to
TFThe TestFixture iteration that the Test belongs to
TThe Test iteration
CategoryThe Test category (set by the Test attribute's Category property)

The Ignored tab is much simpler, since it contains no metrics:

Table 3. Explanation of Columns for Ignored tab

Column NameDescription
FixtureThe name of the TestFixture that the Test belongs to
TestThe name of the Test
InfoThe reason for the Test being ignored

2.6.3. Context Menu Options

The All / Passed Failed tabs provide several options via the context menu:

  • Show All

    If you've set filters using the Filter By option, then this will remove the filters and redisplay all results

  • Compare

    The Compare option allows you to select multiple Tests (i.e. table rows) and compare the results with a graph

    Figure 5. Example of a Comparison Graph

    Example of a Comparison Graph
    • Avg

      Compares the value in the Avg column between all selected test results

    • %

      Compares the value in the % column between all selected test results

    • Ops/s

      Compares the value in the Ops/s column between all selected test results

  • Filter By

    Filter By allows you to select multiple rows, and filter the displayed results according to various options

    • Test

      Will only display results for Tests that have the same Test name as the selected results

    • Test Iteration

      Will only display results for Tests that have the same Test iteration number as the selected results

    • Fixture

      Will only display results for Tests that have the same TestFixture as the selected results

    • Fixture Iteration

      Will only display results for Tests that have the same TestFixture iteration number as the selected results

    • Fixture AND Iteration

      Will only display results for Test that have the same TestFixture name as the selected results AND the same Test iteration number as the selected results

    • Fixture AND Category

      Will only display results for Test that have the same TestFixture name as the selected results AND the same Test Category as the selected results

    • Fixture AND Iteration AND Category

      Will only display results for Test that have the same TestFixture name as the selected results AND the same Test iteration number as the selected results AND the same Test Category as the selected results

    • Assembly Iteration

      Will only display results for Tests that have the same Assembly iteration number as the selected results

    • Thread

      Will only display results for Tests that have the same Thread # as the selected results

    • Category

      Will only display results for Tests that have the same Category value as the selected results

2.7. Output Tabs (Console / Debug / Trace)

Figure 6. Console Tab

Console Tab

The Output tabs display the programmatic output that's generated by the test program:

  • Console Tab

    Displays the values that are output by System.Console.WriteLine(...) commands

  • Debug Tab

    Displays the values that are output by System.Diagnostics.Debug.WriteLine(...) commands

  • Trace Tab

    Displays the values that are output by System.Diagnostics.Trace.WriteLine(...) commands

2.8. Assemblies Tab

Figure 7. Assemblies Tab

Assemblies Tab

The Assemblies Tab is extremely useful for investigating which assemblies are loaded for a specific TestSuite, their underlying components, their locations and version numbers. This can be a great tool when debugging version issues, etc.

It displays the following four values:

Table 4. Assembly Columns

Column NameDescription
NameThe assembly name
VersionThe assembly version
Base LocationThe location of the assembly under normal circumstances (Zanebug copies assemblies into a temporary directory when running tests, so that the original assemblies can still be edited and recompiled while testing)
Test LocationThe location of the copied assembly, which is what Zanebug actually uses for testing purposes. This is a temporary location, and deleted when Zanebug is closed.

2.9. Perfmon Tab

Figure 8. Perfmon Tab

Perfmon Tab

Zanebug allows for integrated Perfmon reporting through a simple to use interface. This relieves developers from constantly switching between multiple applications to track advanced performance statistics.

Note

It's possible to drag-and-drop graphs on top of each other for a consolidated display

Several options and commands are available:

  • Machine Name

    The name of the machine that you want to pull perfmon stats for. This should default to your current machine name.

    Warning

    This feature has not yet been tested for remote computers

  • Load Counters

    The counters are not loaded in Zanebug by default, due to performance issues. In order to load all available counters, click this button.

  • Refresh Display

    When you adjust the various visual properties (Line Thickness, Rows, etc.) you must click this button for the new properties to take affect.

  • Line Thickness

    The thickness of the graph lines

  • Rows

    The number of rows for result graphs. The more rows, the smaller the graph size.

  • Columns

    The number of columns for result graphs. The more columns, the smaller the graph size.

  • Frequency

    The frequency that the graphs are updated. The lower the number, the more often a graph is updated.

  • Density

    The number of draw points in a display