TestComplete lock library files after first run
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-09-2019
12:00 AM
08-09-2019
12:00 AM
TestComplete lock library files after first run
Hi,
I faced with problem when importing several librarys. On first test run everythins works as expected, but if I try to run agait the same routine without re-run testcomplete I get an error.
The problem is that library files was locked by testcomplete process on first run, and they was not released after test is finished.
Here my code:
sys.path.insert(0, Project.Path + '..\\Lib') sys.path.insert(0, Project.Path + '..\\..\\') from APItests import LogGenerator import io nism_ip = ProjectSuite.Variables.NismIP falcon_ip = Project.Variables.MARipageURL.split('/')[2] f = io.StringIO() sys.stdout = f sys.stderr = f def clear_logs(): """ Clear all log events on falcon """ LogGenerator.clear_logs(falcon_ip, nism_ip) print_stdout() def print_stdout(): """ Function to print in Log.Message the 'print()' statement """ output = f.getvalue().split('\n') for o in output: Log.Message(o) f.seek(0) f.truncate(0)
On first run of 'clear_logs()' routine it's passed, but on second run there has error:
SystemError: initialization of _psycopg raised unreported exception 9:52:03 Normal 0.00 The script execution was interrupted. 9:52:03 Normal 0.18
TestComplete locks files for psycopg2 and for lxml librarys.
As workaround I found only one solution - rerun testcomplete
Anyone have sugestions how to fix these issue?
Labels:
- Labels:
-
Test Results
1 REPLY 1
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-09-2019
08:56 AM
08-09-2019
08:56 AM
I suggest that you contact Support with this question. Here's the link:
https://support.smartbear.com/message/?prod=TestComplete
Marsha_R
[Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame
