PC SOFT

WINDEVWEBDEV AND WINDEV MOBILE
ONLINE HELP

Home | Sign in | English UK
  • Overview
  • How to proceed?
  • Testing the current page (session or AWP mode)
  • Events run
  • Stopping the test of a page in session or AWP mode
  • Notes
  • Directory of data files used for test
  • Managing passwords (analysis or data file)
  • Checking the runtime environment before the test
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
Overview
The test of a single page allows you to run the current page in WEBDEV.
This allows you to run the test of your project from a given page or to check the operating mode of a page as soon as it is fully developed.
The debugger can be started during this test.
How to proceed?

Testing the current page (session or AWP mode)

To test the current page (session or AWP mode) from the editor:
  1. Click among the quick access buttons (or press F9).
  2. The editor is automatically minimized and the page is run in the default browser.
Tip: To select the browser used when running the test of the page, click the test icon of the page among the quick access buttons. The arrow on the right expands a menu allowing you to choose the browser that will be used for test.
The choice of the default browser can also be performed in the WEBDEV options. To select the test browser, go to the "Project" pane, "Test mode" group, expand "Test mode" and select "Test browser".
Remarks:
  • When running the test of a page that expects one or more parameters, a window for entering the parameters is automatically displayed.
  • To start the debugger, all you have to do is use the STOP keyword in the code or a breakpoint.
  • Versions 21 and later
    The last test run (window, query, report, ...) can be re-run from any project element via "GO .. Re-run the last test" found in the quick access buttons.
    New in version 21
    The last test run (window, query, report, ...) can be re-run from any project element via "GO .. Re-run the last test" found in the quick access buttons.
    The last test run (window, query, report, ...) can be re-run from any project element via "GO .. Re-run the last test" found in the quick access buttons.

Events run

The following WLanguage events are run at the start of the test of a page (session mode):
  • Declaring the classes (server code)
  • Initializing the project (server code)
  • Global declarations of the current page (server code)
  • Initializing the controls found in the current page (server code)
  • Initializing the current page (server code)
  • Loading the current page (browser code)
  • Entering the first control of current page (if this control has an entry process) (browser code)
At the start of the test of an AWP page, the page is run with an URL containing the parameters of the page and the command line of the project. To define the command line of the project, go to the "Project" pane, "Test mode" group, expand "Test mode" and select "Configure test mode". The following WLanguage events are run:
  • Declaring the classes (server code).
  • Initializing the project (server code).
  • Global declarations of the current page (server code).
  • Initializing the controls found in the current page (server code).
  • Initializing the current page (server code).
  • Loading the current page (browser code).
  • Entering the first control of the current page (if this control has a "Control entry" event) (browser code)
During the test:
  • the initialization codes (project, classes, sets of procedures, ...) are re-run whenever an action is performed in the AWP page and whenever a new AWP page is displayed.
  • All the features of the page can be run. You will have the ability to open other pages for example. When going from a page to another one (PageDisplay for example), the debugger locks the execution of the next page as long as the previous page has not been entirely traced.
  • InTestMode returns True.

Stopping the test of a page in session or AWP mode

Several methods can be used to stop the test:
  • 1st method: Close the site whose test is currently run. WEBDEV displays the editor that was used at the beginning of test.
  • 2nd method: Go back to the editor with the taskbar (or Alt + Tab) and confirm that the test must be stopped. WEBDEV displays the editor that was used at the beginning of test.
Notes

Directory of data files used for test

To configure the data files used when running the application test in the editor:
  1. Open the project description: on the "Project" pane, in the "Project" group, click "Description".
  2. In the "File" tab, select the location of the test data files:
    • Current directory: The data files will be in the project EXE subdirectory.
    • Specific directory: The data files will be found in the specified directory.

Managing passwords (analysis or data file)

No password is requested during the test of the dynamic page, regardless of whether the page is associated with an analysis protected at runtime or with a password-protected data file.
The necessary passwords must be specified by programming in the "Initializing" event of the project:
  • If the page handles a data file from a password-protected analysis, this password must be specified with HOpenAnalysis.
  • If the page handles one or more password-protected data files, this password must be specified with HPass.
A WLanguage error occurs when testing the page if the passwords are not specified in the "Initializing" event of the project.
Versions 15 and later

Checking the runtime environment before the test

Before running a project test, WEBDEV checks whether the test environment is properly configured.
If a problem is detected, WEBDEV proposes to display the diagnostic window:
Proposition of diagnostic for the test environment
The available options are as follows:
  • "Start the diagnostic" opens the window for detailed diagnostic.
  • "Run the test" ignores the diagnostic and runs the test. This option must be used if the diagnostic is incorrect.
  • "Cancels" cancels the test.
The window for detailed diagnostic is as follows:
Details of the diagnostic
This window performs a set of tests to check whether the test environment is properly configured.
For each detected error, a "Correct" button is used to automatically restore the correct test environment.
The "Help" button will be enabled if an additional help is available.
New in version 15

Checking the runtime environment before the test

Before running a project test, WEBDEV checks whether the test environment is properly configured.
If a problem is detected, WEBDEV proposes to display the diagnostic window:
Proposition of diagnostic for the test environment
The available options are as follows:
  • "Start the diagnostic" opens the window for detailed diagnostic.
  • "Run the test" ignores the diagnostic and runs the test. This option must be used if the diagnostic is incorrect.
  • "Cancels" cancels the test.
The window for detailed diagnostic is as follows:
Details of the diagnostic
This window performs a set of tests to check whether the test environment is properly configured.
For each detected error, a "Correct" button is used to automatically restore the correct test environment.
The "Help" button will be enabled if an additional help is available.

Checking the runtime environment before the test

Before running a project test, WEBDEV checks whether the test environment is properly configured.
If a problem is detected, WEBDEV proposes to display the diagnostic window:
Proposition of diagnostic for the test environment
The available options are as follows:
  • "Start the diagnostic" opens the window for detailed diagnostic.
  • "Run the test" ignores the diagnostic and runs the test. This option must be used if the diagnostic is incorrect.
  • "Cancels" cancels the test.
The window for detailed diagnostic is as follows:
Details of the diagnostic
This window performs a set of tests to check whether the test environment is properly configured.
For each detected error, a "Correct" button is used to automatically restore the correct test environment.
The "Help" button will be enabled if an additional help is available.
Minimum version required
  • Version 9
Comments
Click [Add] to post a comment