Comparing table data in IF not working
Hello, I have this weird problem were everything seems correct but TC isn't doing the correct steps. I have a data driven loop, and I am going to check if the product number is a specific product, and it should do the steps I want. This has worked in the past, not sure why it stopped working. In the image below, in the blue box, the product number is filled in - this is correct. For the sake of testing, I added the yellow box - these also give and store the correct values. The problem is in the red box, for some unknown reason it just skips the if. Below is a small snippet of the test log, and you can see that the log action provided the correct product number. Also, you can see that the text in the textbox is also the correct value. And lastly a screenshot of the if itself. Can anybody help me notice the issue? Thanks in advance. LuukSolved7.9KViews0likes28CommentsTest Fails When Running with Tag: Double Parameter Default Issue
Hey, fellow community, I'm facing an intriguing issue with one of my tests, and I was hoping to get some insights from you all. Here's the problem: I have a test that includes an optional double parameter, and its default value is set to 10000. When I manually run the test, everything works perfectly, and the default value of 10000 is used as expected. However, the trouble starts when I try to run the test using the tag. I use the right-click option on the project and run the test with the tag '@tag'. Surprisingly, the test fails, and upon further investigation, I noticed that the value used for the double parameter is 0 instead of my intended default value of 10000. I've already double-checked the tag setup and made sure everything looks correct. It's puzzling why the default value is being ignored when using the tag, leading to the failure. Has anyone encountered a similar issue before or have any ideas about what might be causing this discrepancy? I'd greatly appreciate any suggestions, tips, or experiences you can share to help me troubleshoot this problem and get my test running successfully with the tag. Thank you all in advance for your support and insights!Solved6.8KViews1like17Commentsjenkins pipeline catch the exit code 0
Hello, I need you're help, i am using Testcomplete 15 and TestExecute 15 with jenkins With jenkins pipeline def RunTest(String TestInfos) { try { testcompletetest actionOnErrors: 'MAKE_FAILED', actionOnWarnings: 'MAKE_UNSTABLE', credentialsId: 'VEGA-TEST', executorType: 'TE', launchType: 'lcItem', project: 'Macro_Standard_Beta', sessionScreenResolution: '1920x1080', suite: 'Alocpro\\Alocpro.pjs', useTCService: true, test: "$TestInfos" stageResult = 'SUCCESS' echo "< Build SUCESS >" } catch (Exception e) { catchError(stageResult: 'FAILURE') { sh "exit 1" } echo "< Build Failed >" } } pipeline { agent { label 'Srv-Test01' } options { timeout(time: 1, unit: 'HOURS') } stages { stage('Reset BDD Beta') { steps { script{ RunTest('Beta_02_Reset_BDD') } } } stage('CartesCarburant') { steps { RunTest('Avancee1|Beta_2_01_CartesCarburant1') } } stage('Contentieux') { steps { RunTest('Avancee1|Beta_2_02_Contentieux') } } stage('Contraintes') { steps { RunTest('Avancee1|Beta_2_03_Contraintes') } } /* stage('CRM') { steps { RunTest('Avancee1|Beta_2_04_CRM') } } stage('EtatStatistique') { steps { RunTest('Avancee1|Beta_2_05_1_EtatStatistique') } }*/ stage('Financement') { steps { RunTest('Avancee1|Beta_2_06_Financement') } } stage('Comptabilite') { steps { RunTest('Avancee1|Beta_2_07_0_Comptabilite') } } stage('Assurance') { steps { RunTest('Avancee1|Beta_2_08_Assurance') } } stage('GestionDesPetroliers') { steps { RunTest('Avancee1|Beta_2_09_GestionDesPetroliers') } } stage('Prestation') { steps { RunTest('Avancee1|Beta_2_10_Prestation') } } } post { failure { emailext body: '''$PROJECT_NAME - Build # $BUILD_NUMBER - $BUILD_STATUS : \n $BUILD_LOG maxLines=8000, escapeHtml=true \n \n Check console output at $BUILD_URL to view the results.''', recipientProviders: [brokenBuildSuspects()], from: '##', subject: 'Build failed in jenkins : $PROJECT_NAME - Build # $BUILD_NUMBER - $BUILD_STATUS!', to: '##', attachLog: true } unstable { emailext body: '''Build unstable - $PROJECT_NAME - Build # $BUILD_NUMBER - $BUILD_STATUS : unstable\n $BUILD_LOG maxLines=8000, escapeHtml=true \n \n Check console output at $BUILD_URL to view the results.''', recipientProviders: [brokenBuildSuspects()], from: '##', subject: 'Build instable in jenkins : $PROJECT_NAME - Build # $BUILD_NUMBER - $BUILD_STATUS!', to: '##', attachLog: true } fixed { emailext body: '''$PROJECT_NAME - Build # $BUILD_NUMBER - $BUILD_STATUS : Back to normal !\n Check console output at $BUILD_URL to view the results.''', recipientProviders: [brokenBuildSuspects()], from: '##', subject: 'Build back to normal : $PROJECT_NAME - Build # $BUILD_NUMBER - $BUILD_STATUS!', to: '##' } } } The jenkinspipeline works, but in my jenkins view i dont have my stage in red when it failed. What i would like to do is to catch the exit code =! 0 and setstageResult = 'FAILURE' But the other stages needs to continue even if one of them failed there are independent I have triedcatchError steps but this is not really what i want. In this exemple the try catch does nothing even if a test crashed because of the exit code which seems not to be handled in jenkins this way The error i did in this scenario is in purpose to test the exitcode I have linked a log of the lastest execution i did >logs jenkins.txt Is there a way to catch the exitcode in jenkins? Thanks6.5KViews0likes0CommentsRead excel data/links in javascript test complete
Hi team, I have tried to read the data file using javascript in test complete.But shows error as "Type error: cannot read the property 'SheetByTitle' of null" functionExcelRead() { varexcelFile = Excel.Open("C:\\temp\\DataStorageExcel.xlsx"); varexcelSheet = excelFile.SheetByTitle("Sheet1"); varvalueA = excelSheet.Cell("A", 3).Value; varvalueB = excelSheet.Cell(2, 3).Value; varvalueC = excelSheet.CellByName("C3").Value; } Can any one help regarding this issue or I want to fetch the weblinks from excel file one by one that links need to execute. Thanks in advance.Solved5.3KViews0likes4CommentsTrying to call the FindChild method or property of an object but it does not exist
Hello, can someone help debug the following script, I cannot figure it out why it's failing being I am new to TC. I included the screenshot of the properties from the Spy captured,I am sure the page ID is correct according to the spy screen. function DragCard() { // Find the first column element var column1 = Sys.Browser("chrome").Page("https://rdx-dev.rdxhub.com/workspace/patient-board").FindChild("idStr", "chk-drop-list-0", 10); // Find the card element in the first column with the desired text content var cardToMove = column1.FindChild("contentText", "Test Patient455", 10); // Find the second column element var column2 = Sys.Browser("chrome").Page("https://rdx-dev.rdxhub.com/workspace/patient-board").FindChild("idStr", "chk-drop-list-2", 10); // Drag the card to the second column cardToMove.Drag(column2); }Solved5KViews0likes12CommentsKeyword Tests: create an object by concatenating variables or parameters
I have the path below: Sys.Process("InteleRIS").WinFormsObject("mdiRIS").WinFormsObject("MdiClient", "").WinFormsObject("frmPatientMain").WinFormsObject("tabPages").WinFormsObject("UltraTabPageControl23").WinFormsObject("pnlApptRequests") Now, this is used within a small keyword test which is called from other test cases. The last part of this path (the bolded one) should be a parameter whichI am throwing in when I call thistest. So basically because this value is dynamic, I need to create an object by concatenating the path with a parameter in the last part of it and then use this object todo different actions on it, like IsVisibleOnScreen. I have tried something like next (but it does not work, tried with Variables and Parameters as well): Sys.Process("InteleRIS").WinFormsObject("mdiRIS").WinFormsObject("MdiClient", "").WinFormsObject("frmPatientMain").WinFormsObject("tabPages").WinFormsObject("UltraTabPageControl23").WinFormsObject(" + KeywordTests.PatEdit_CheckCorrectTabIsDisplayed.Parameters.ExpectedPatientEditTabName + ") Please suggest. Note: I need this as a keyword test(but I don't mind a VB script example as well) Thank you.Solved3.5KViews0likes7CommentsCalculate value of variable using parameter default value and an on-scree object variable value
I have a parameter (InvoiceAmount),which has a default value of 1000. I have a variable (discount),whose valueI get from an on-screen object. I need to calculate the value of Amount (which is another vaiable). I need this value to be stored and entered into the text field of another on-screen object. The calculation is simple - Amount = Invoice Amount - Discount. I am not sure how to reference parameters and variable in VBScript. I keep getting an error that it is not running the test. I also tried 'Run Code Snippet' with value as Execute(KeywordTests.MY_Test.Parameters.Invoice_Amount - KeywordTests.MY_Test.Variables.Discount_Amount). However, it just enters this string as the value into the on-screen, text field instead of the calculated value. Any help or suggestions would be greatly appreciated. Deepa.Solved3.2KViews0likes7CommentsGenerate Data - not generating random strings but saves a default value
I have a Reference field, where I am entering a random string (min 1 to max 20 chars) andI need this to be unique with a combination of 2 other fields. I've created this variable using Data Generator > String type, using a combinaion of numbers, letters and space. On the 1st test run, it generates a random string. But after this, itsaves this value as the default. So on all my subsequent test runs, instead of generating a new random string, it is using this default value and so it is not a unique reference. I used the 'One value' variable type. Can anyone suggest what I might be doing incorrectly? Thanks!Solved2.6KViews0likes4CommentsHow to run a TestComplete test between mutiple instance of Chrome using different user profile
Hello. In Test Complete, Is it possible to open two instances of Chrome at the same time using different user profile, and executing the tests between both profiles? The reason of my question is that I have the following manual test case I would like to automate using 2 chrome sessions running at the same time. It is important for both Chromes not to use the same user profile. 1) LaunchChrome (1) usingprofile(1) 2) On Chrome (1) - Log on as user1 onto the web app. 3) On Chrome (1) - Create a patient and assign patient to user 2. 4) On Chrome (1) - Make the call for user2 to accept the patient. 5) Start another session of Chrome, but with profile (2) and keeping the other session of Chrome(1) opened. 6) On Chrome (2) - Log on as user2 7) On Chrome (2) - Check patient is in user 2 list. 8. On Chrome (2) - Accept user 1 call and perform a few actions. 9) On Chrome (2) -user 2 return patient to user1 10) Return to Chrome (1) 11) On Chrome (1) -User 1 ends the patient visit after a few actions 12) Both users logs out. I hope someone can help explain how it can be done by example. Thank you.Solved2.3KViews0likes23CommentsGet & save dynamically generated value in 1 test & pass it as variable in another test
I have a form, where I fill in some information and when it is saved, it generates an Order Number. I want to get and save thatvalue in a variable. WhenI use the Property Checkpoint here,can I save the value that is found in that field into a variable instead ofassigning the value towText property.I then want to be able to refer to this variable in other tests, where I want to do some action on some rows of data where, the order number is that saved value. New to TestComplete and automation and would appreciate any help. Thanks!Solved2.3KViews0likes3Comments