Information in this topic applies to desktop applications only. |
Connected and Self-Testing applications are deprecated. These technologies will be removed in one of the future releases of TestComplete. To create test code that runs from within your tested apps, use TestLeft, a SmartBear functional testing tool for developers. |
TestComplete is built on an open, COM-based architecture. The testing engines, which the scripting object uses, can be reached from TestComplete as well as from the outside through TestComplete COM interfaces. This gives you the possibility to create special external testing applications and easily port the script code to the application’s code. That is, you can record script code, try it out and debug it inside the TestComplete user interface, and then port this script code to the application's code. One possible reason for moving the script code and creating special testing applications is more control over the test execution. The testing application can implement complex test logic, waiting loops and conditions. Another reason is deeper access to the internal objects of the application under test (the test code placed to the tested application have the same access to application objects, methods and properties as the application code, that is, you can easily get a self-testing application).
Imported script code can be extended to use application libraries, symbolic constants, classes and ordinary types. It can be compiled with the full syntax-check facilities of the compiler, and debugged with the development environment’s own debugger.
The porting is available only for those applications, whose language corresponds to the scripting language. Some scripts can be ported directly, some others require some changes. For instance, since DelphiScript is simply a subset of Object Pascal, DelphiScript routines can be imported to Delphi applications and compiled directly. The same is true for Microsoft Visual Basic applications and VBScript. Moving of C++Script and C#Script code to C++ and C# applications requires changes. See Writing C++ Scripts and Writing C# Scripts for more information.
The following topics contains detailed information about creating testing applications:
Connected Applications - Overview
Creating Connected Applications in C++
Creating Connected Applications in C#
Creating Connected Applications in Visual Basic .NET
Creating Connected Applications in Visual Basic 6.0
Creating Connected Applications in Delphi
Creating Scripting Objects From Application Objects
Running Connected and Self-Testing Applications
Connect
class that stores wrappers for TestComplete runtime objects.Using the var Type in C# Connected Applications
Sending Messages to the Test Log From Your Applications