Mantis Bugtracker          
testlink.org

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0006840TestLinkImport results XML formatpublic2014-12-15 22:532014-12-31 14:22
ReporterMr.Bricodage 
Assigned Tofman 
PrioritynormalSeverityminorReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version1.9.12 (2014 Q3) 
Fixed in Version1.9.13 (2015 #1) 
Summary0006840: [Import test execution results] Ignore test results if already exists in TestLink (with same execution timestamp)
DescriptionDuring an import, if a result is already known in TestLink, the import function should ignore the imported data to avoid duplicates entries.
Steps To Reproduce1) use "export for results import" function
2) fill the xml file for one testcase
3) Import the xml file a 1st time => the result is saved by testlink import function
4) Import the xml file a 2nd time => the result is saved again by testlink import function

==> The 2nd import should be ignored (based on timestamp)
Additional InformationIt is usefull to import execution results even if all testcases of a TestPlan has not be executed yet (to use TestLink reports ans statistics).

TagsNo tags attached.
Database (MySQL,Postgres,etc)All
BrowserChrome
PHP Version5.4.24
TestCaseID
QA Team - Task Workflow StatusREADY FOR TESTING
Attached Filesjpg file icon ImportFilterTimestamp.JPG [^] (31,783 bytes) 2014-12-15 22:55


jpg file icon before.JPG [^] (69,348 bytes) 2014-12-15 22:58

- Relationships
child of 0006609closedfman Availables hot-fixes for 1.9.12 & How To get full fixed package from gitorious 

-  Notes
(0022373)
Mr.Bricodage (updater)
2014-12-15 22:55

https://gitorious.org/testlink-ga/testlink-code/merge_requests/23 [^]
(0022374)
fman (administrator)
2014-12-16 11:37

>> During an import, if a result is already known in TestLink,
Can you kindly explaing what is an already known result ?

>> the import function should ignore the imported data to avoid duplicates entries.

The sentence on additional information does not make things clear (IMHO)

Try to spend a little more time when reporting explaining in a way other users can take advantage of this implementations.
(0022377)
Mr.Bricodage (updater)
2014-12-16 17:58

ok, I'm sorry, second attempt :

During an import, if a result has already been imported into TestLink (comparaison based on execution timestamp), the import function should ignore the imported data to avoid duplicates entries. This 'ignore mecanism' allow to import the same file several times with 'old' execution data (already imported) and new execution data.

Additionnal information (use case):
I use a testplan export (4 months to test all functionnalities) and want to import partial result every month (to use TestLink reports ans statistics).
With actual comportment, execution data imported after 1 month is imported again during 2nd, 3rd and 4th import (each time with same information). Look at "before.jpg" to see a testcase execution history after several imports for the same testplan.

With modified comportment, execution data already imported during 1st month is not saved again during 2nd, 3rd and 4th import (comparaison of the execution timestamp to know if execution shoud be saved). All 'duplicates' entries in execution history are not present anymore.
(0022378)
fman (administrator)
2014-12-16 18:04

OK thanks for the update of documentation.
I've just finished to refactor the code and I'm commiting.
Please get and test.
IMHO in your solution you have ignored platforms.

I've also done changes to standard methods on testcase class to reduce amount of data on query that seems to need only execution_ts

Thanks again for your collaboration
(0022379)
fman (administrator)
2014-12-16 18:05

https://gitorious.org/testlink-ga/testlink-code/commits/f1a03a0c43067dc45904f2a1fca9adeff75b0eb9 [^]
(0022384)
Mr.Bricodage (updater)
2014-12-17 20:18

I just tested your code.
Works fine with English wide/UK.

However, problems are present using french :

1) variable name in string.txt for french hasn't been adapted :
"$TLS_import_results_filtered" must be replaced with "$TLS_import_results_skipped". The correct translation into the french string.txt of the text you have defined in English "string.txt" is :
$TLS_import_results_skipped = "Cas de test %s - Version %s - Testeur: %s - Resultat : %s - " .
                              "Horodage d'exécution : %s - NON IMPORTE (même cas de test, version, Horodatage)";

2) the result string (passed, failed, blocked) is always in English even if another language is selected. The same occurs when using $TLS_import_results_ok (I didn't noticed it before). Maybe that should be the subject of a new bug?

Thank you
(0022386)
fman (administrator)
2014-12-18 08:37
edited on: 2014-12-18 09:03

>> 1) variable name in string.txt for french hasn't been adapted :
OK, my fault I'm going to update
(https://gitorious.org/testlink-ga/testlink-code/commits/a83a7e0abe3927e46cd95cacf755ef56a60eb858 [^])


>> 2) the result string (passed, failed, blocked) is always in English
Need to check because theoricaly I use labels => are localized

https://gitorious.org/testlink-ga/testlink-code/commits/4ec03a2046c2890cbd39641be62c1b6e5737d6d8 [^]


- Issue History
Date Modified Username Field Change
2014-12-15 22:53 Mr.Bricodage New Issue
2014-12-15 22:55 Mr.Bricodage Note Added: 0022373
2014-12-15 22:55 Mr.Bricodage File Added: ImportFilterTimestamp.JPG
2014-12-15 22:58 Mr.Bricodage File Added: before.JPG
2014-12-16 11:37 fman Note Added: 0022374
2014-12-16 13:11 fman QA Team - Task Workflow Status => TBD
2014-12-16 13:11 fman Category Export/Import => Import results XML format
2014-12-16 13:11 fman Summary [Import test execution results] Ignore test results if already known in TestLink => [Import test execution results] Ignore test results if already exists in TestLink (with same execution timestamp)
2014-12-16 17:58 Mr.Bricodage Note Added: 0022377
2014-12-16 18:04 fman Note Added: 0022378
2014-12-16 18:05 fman Note Added: 0022379
2014-12-16 18:05 fman Assigned To => fman
2014-12-16 18:05 fman Status new => feedback
2014-12-16 18:05 fman Relationship added child of 0006609
2014-12-17 20:18 Mr.Bricodage Note Added: 0022384
2014-12-17 20:18 Mr.Bricodage Status feedback => assigned
2014-12-18 08:37 fman Note Added: 0022386
2014-12-18 08:46 fman Note Edited: 0022386 View Revisions
2014-12-18 09:03 fman Note Edited: 0022386 View Revisions
2014-12-18 09:03 fman QA Team - Task Workflow Status TBD => READY FOR TESTING
2014-12-18 09:03 fman Status assigned => resolved
2014-12-18 09:03 fman Fixed in Version => 1.9.13 (2015 #1)
2014-12-18 09:03 fman Resolution open => fixed
2014-12-31 14:22 fman Status resolved => closed



Copyright © 2000 - 2018 MantisBT Team
Powered by Mantis Bugtracker