Testiny-importer-macos testrun cannot found test cases into folders

Hi, i’m trying to create a test run with testiny-importer-macos and it doesnt create a Test run when the Test Case is inside a subfolder, if the Test Case its inside a folder, it works.

My command;

Users/user/Testiny/testiny-importer-macos testrun /testiny-importer-macos testrun \
   --confirm    \
   --disable-nested-folders     \
   --testcases ignore      \
   --name 'test'           \
   --testplan 'x'          \
   --project 'Pruebas automaticas'      \
   --junit  'resources/reports/TESTS-private.home.xml'




¿Am i doing something wrong?

Thank you so much.

Hi Adam,

It’s a bit hard to analyze this issue without seeing the junit XML file, so I’m mostly guessing:

The problem could be that your tests are all named “test”. Testiny tries to match the test results with test cases and the only key in this case would be the name. Then both results would link to the same test case and override each other.

Have you tried naming your test cases differently?

Best Regards,
Alex

Hi,

This is my Test Plan named “x”

This is my subfolder with Test Case named: “testcasesubfolder”

This is my foldertwo with Test Case named: “testcasefoldertwo”

The junit XML file for my Test Case named: “testcasefoldertwo” is this and works perfectly:

And this is my junit XML file for my Test Case named: “testcasesubfolder”:

Testiny importer gave me this:

 o---o  ----------------------------
   |      TESTINY IMPORTER  1.10.0
   \-o  ----------------------------

API key: user '------ in organization 'app'
Using project: ------
Using test plan: x (20) 
JUnit XML import: 1 rows
Importer will import 1 test case results to existing test run 'Home'
JUnit XML import: 1 rows
Testrun 'Home' was updated and 0 test case results were added/updated
Import success

But when i try with my Test Case named: “testcasefoldertwo” it works and gave me this:

 o---o  ----------------------------
   |      TESTINY IMPORTER  1.10.0
   \-o  ----------------------------

API key: user '------ in organization 'app'
Using project: ------
Using test plan: x (20) 
JUnit XML import: 1 rows
Importer will import 1 test case results to existing test run 'Home'
JUnit XML import: 1 rows
Testrun 'Home' was updated and 1 test case results were added/updated
Import success

Hi Adam,

Ahh, ok, now I understand the problem :slight_smile:

By default, the importer takes the folder structure into account when matching results to test cases. That means, the junit results corresponding to a test case in a subfolder would need to be in two stacked testsuite nodes.

However, you can configure that matching should use the test case title only:
--duplicates title

And just for you info: the --disable-nested-folders only applies to CSV imports for now, i.e. to imported test cases or results which do not already have a folder structure by default (e.g. for junit the folder structure is determined by the nested testsuite nodes). So you can omit that option.

Best Regards,
Alex