Skip to content

Latest commit

 

History

History
213 lines (127 loc) · 9.2 KB

FEATURES.md

File metadata and controls

213 lines (127 loc) · 9.2 KB

FEATURES - Table of Contents

Gtest-runner

A Qt5 based automated test-runner and Graphical User Interface for Google Test unit tests

Automatic test running

Automatic test running

  • Gtest-runner uses file system watchers do detect every time your test has changed (e.g. when you build it), and automatically re-runs the test and updates all the test case windows. This feature even works if you rebuild your test when gtest-runner is closed.
  • Gtest-runner runs all of your tests in parallel, showing a progress indicator for each one.
  • Note: for expensive or lengthy tests, automatic test running can be disabled by unchecking the box next to the test name.

Simple traffic-light output

Traffic light

  • - A green light means that the test was run and all test cases passed with no errors.
  • - A yellow light means that the test has changed on disc and needs to be re-run. If your test executable is corrupted, deadlocks, or segfaults, you may see a test in a "hung" yellow state.
  • - A red light means that the test executable failed at least one test case.
  • - A gray light indicates that the test is disabled, or if autorun is disabled it can also indicate that test output is out-of-date.

Full console output

console

  • All gtest console output is reatined (including syntax highlighting) and piped to the built-in console dock, so you get all the benefits of a GUI without losing any of your debugging output. Plus, gtest-runner adds additional capabilities like a search dialog and forward and backward failure navigation buttons.

Fully customizable layout

tab

  • Gtest-runner uses detachable docks for the test executable, failure, and conosle docks, so you can tab, rearrange, detach, or hide them to best suite your screen layout.

Light and dark themes

light theme dark theme

  • Easily switch between your system's default color theme or a breeze-inspired dark theme.

System notifications

System Notification

  • When a test is autorun in the background, gtest-runner will generate a system notification letting you know if any tests failed. Notifications can also (optionally) be configured for tests which pass during autorun.
  • Note: notifications aren't generated for tests which are run manually (since you are presumably already looking at the output).

Gtest support

  • Gtest-runner supports both gtest-1.7.0 and gtest-1.8.0 style output.

Test Executable dock

Test Executable Dock

Drag-and-drop

  • To add a test executable to watch, simply drag-and-drop the test executable file anywhere on the gtest-runner GUI.

Easily add and remove tests

Add/remove

  • In addition to drag-and-drop, it's easy to add or remove a test using the right-click context menu in the Test Executable window.

Re-run test

Re-run test

  • You can manually re-run a test at any time by right-clicking on it and selecting Run Test...

Kill test

Kill test

  • Did you just actually click run on your 4-hour CPU intensive test? No problem! Cancel a test at any time by right-clicking on it, and selecting Kill Test....
  • Hint: if the Kill Test... option is grayed out, that means your test isn't running (even if it has a yellow indicator).

gtest command line options

gtest command line

  • Clicking on the hamburger menu to the left of the test executable name will pop up the gtest command line dialogue, allowing access to all of the options you'd have if you ran your test directly from a terminal.

Enable/disable autorun

disable autorun

  • Compiling frequently, or have a resource-intensive test that you don't want running in the background? Whatever the reason, it's simple to disable autorun by un-checking the autorun box next to the test executable name.

Test progress

Progress

  • Each running test displays a progress bar indicator. Measured progress is based on the number of tests completed out of the overall number of tests, not time-to-go.

Test path tooltips

Path

  • Mousing over any of the test executables will show the full path to the test as a tooltip. This can be useful for disambiguating multiple tests with the same name. On Windows, Debug and Release builds are differentiated automatically.

Test case window

Test Case Window

Detailed failure information

Detailed failure information

  • Clicking on any failed test case will display detailed information about each EXPECT/ASSERT failure in the Failures window.
  • Note: No detailed information is available for test cases which pass or are disabled.

Sort failures

Sort

  • The test case list can be sorted by any column. The default sort is the to show the tests in order. To change sort, just click on any of the column headers. Click the header again the alternate between ascending/descending order.
  • Note: The current sort column is indicated by the arrow ofabove the column title (in this example, Failures).

Filter failures

filter

  • Filter the test cases displayed by typing into the filter text box. Only matching results will be shown.
  • Note: The filter text edit accepts regex filters as well!

Failure window

failure window

Jump to console output

Jump to console output

  • Single clicking any failure in the failure window will automatically jump to the corresponding output in the gtest console.

Open in IDE

  • Double clicking any failure will automatically open the file in your IDE (or whichever program is associated with the file extension). It will also copy the line number of the failure to the clipboard. In almost every editor, you can then quickly jump to the failure location with the shortcut Ctrl-G, Ctrl-V, ENTER.

Full GTest error message

Full error

  • Hovering the mouse over any failure will show a tool-tip with the original, un-parsed gtest error message.

Console Window

Console

Search

Find

  • Open a Find window with the keyboard shortcut Ctrl-F, or by right clicking in the console window and selecting it from the menu. You can use the Find dialog to search the console output for specific failures or std::cout messages.

Next/previous failure

Next/previous failure

  • Use the buttons on the left side of the console window to quickly scroll to the next or previous failure.

Clear output from previous runs

Clear

  • Is your console output getting cluttered with too many runs? Easily clear it by selecting the clear option from the right-click context menu.

Cout

Cout

  • Like to mix std::cout debuggin with your gtests? No problem! All of your custom error messages are visible in the console window.