GXtest Menu Commands

Official Content
This documentation is valid for:

GXtest provides some commands that allow creating and running tests in a Knowledge Base. Among them, you can distinguish two types of commands: global commands and contextual commands.

Global commands or operations

Run All Tests

Builds and runs all enabled tests present in the KB, i.e. unit tests, web UI tests, and UI tests.

Shortcut: Ctrl + Shift + R

Run_All_Tests_v17u9_png

Rebuild All Tests

Rebuild all enabled tests and, therefore, the objects called by them.

Rebuild_All_Tests_v17u9_png

Run Current Test

Run the current test being edited or the object unit tests if the object being edited is a testable object.

Shortcut: Ctrl + R

Record Web UI Test

Creates, records and saves a new web UI test using GXtest Recorder extension: see more information about this feature in the Recorder-IDE integration article.

Record_Web_UI_Test_v17u9_png

Stop Tests Execution

Stops the current tests execution in progress, or the build process, if any.

Stop_Tests_Execution_v17u9_png

Tests Build Type

Allows choosing the type of build performed (if any) when a test execution is done. The options are the following:

  • Build: a build operation is performed with the selected tests. Default value.
  • Rebuild: a rebuild operation is performed with the selected tests
  • These Only: a build with these only is performed with the selected tests
  • No Build: no build operation is performed whatsoever. Therefore tests are immediately run.

This setting is saved as a local KB property, this means it is stored locally and remembered each time you open the KB, but it is not committed to GXServer. Additionally, a shortcut is displayed in the toolbar so it is easier to modify it.

TestBuildOptions_20221116152541_1_png

Contextual menu options

These options are available when specific objects are selected, typically tests or unit-testable objects (procedures, data providers, and business components).

Run Test(s)

  • Target objects: tests or suites. It becomes available for a selection from one to any number of test objects exclusively. Disabled when there is a test execution in progress.
  • Action: Run the selected test objects.
  • Shortcut: Ctrl + R

Run_Tests_v17u9_png

Run Unit Tests

  • Target objects: unit-testable objects: procedures, data providers, and business components. It becomes available for a single unit-testable object. Disabled if there is a test execution in progress.
  • Action: Run the unit tests that call the selected object.
  • Shortcut: Ctrl + R

Run_Unit_Tests_v17u9_png

Create Unit Test

  • Target objects: unit-testable objects: procedures, data providers, and business components. It becomes available for a single unit-testable object.
  • Action: Creates a unit test for the selected object according to Test Generation properties set for the current KB.

Create_Unit_Test_v17u9_png

Create Rest Test

  • Target objects: objects exposable as Rest services. It becomes available for a single object.
  • Action: Creates a Rest test for the selected object according to Test Generation properties set for the current KB.

CreateRestTest_png

Record Mocking Data

  • Target objects: unit tests. It becomes available for a single unit test selection. Disabled if there is a test execution in progress.
  • Action: Run the selected unit test, recording all queries to the database during its execution. See Database Mocking for more information about this feature.

Record_Mock_Data_v17u9_png