Test Studio: Playback instantly completes when datafile is used

I’m currently in the process of setting up test studio to run a scenario through our application. Due to the nature of process the case used to record the test cannot be used to play it back as the final state for the case would cause the test to fail.

I’ve therefore downloaded the data template and updated the data line to point it at the case reference for the new case that I would like to run the test on. However, on execution the test instantly completes saying playback passed, looking at the log, no steps are actually completed.

I’m now in the process of recording the test again under a new name so I can check if the original is corrupted in some way.

Has anyone come across anything similar and if so were you able to resolve?

Hi @Dominic ,

Data files is one way of doing this, and the fact it doesn’t work for you suggests there could be a potential bug. I would advise raising that via our Community Support Portal.

However, another way to tackle this scenario is ensuring you are creating a record within the suite you trigger this in. Reason being is that Test Studio is able to identify and utilise data created upstream.

For example, let’s say you had 3 tests within a suite:
Test 1) Add a case
Test 2) Progress the case
Test 3) Add a comment to the case

Within Test 1, you should have a step that views the record, and the selection method when editing the step will offer Created upstream as an option. What this will do is access the context record of the record you just created (as opposed to you defining a fixed/pre-created record).

This is ideal as, when running via Suites, Test 2 can be configured to load a page and start from a context record and progress the case, and during the suite execution it will run from the record created upstream.

Hope this makes sense.

I have, however, found there is an issue with displaying the Created upstream option in Test Studio and have raised a bug accordingly to get resolved. I will notify you soon when this option has been re-instated.

Hope this helps :slight_smile:

1 Like

Hi @ali.bandali ,

Thanks for getting back to me, I’ve got a ticket open for the issue currently. I’ve had mixed results with the data files, some tests (generally the smaller ones) seem to work just fine with the data file but the times where I’ve experienced this issue have been in the region of 1000 steps.

The created upstream option does sound promising, would that preclude the need to create a datafile for tests that run after the initial case creation?

Hi @Dominic ,

Wow, 1000 steps! That’s a big test.
I’ll get in touch with the support team and liaise with them on this one, see if I can assist in any way.

To answer the Created upstream inquiry, yes and no - it does preclude data files in your example, but can also work alongside them to create dynamic tests :slight_smile: it’s super useful and makes for a more efficient test design.

For example, you might decide to have a single test, which adds the record AND progresses it in the same test. In this example, you are using the Created upstream method to identify the record created and progress it. Once you’re happy with the test, you could then add a datafile to ensure the process is run against multiple records - Awesome, right?

That being said, it’s all in the test design and how your application is designed. Using your example of processes, it’ll depend on your process model and how it has been configured, whether it’s a dynamic process, how it’s progressed (etc).
To give a short example, you may have a choice field which determines whether a process step is skipped or a dynamic process comes into play. In this scenario, a single test would not work.

Information overload, but, I hope this helps :slight_smile:

Hi @ali.bandali ,

Thank you for taking a look, I’ve added notes to the ticket detailing the steps to recreate as I was unable to reply to Greg’s email. I’ve also added details of another test where I seem to be encountering the same issue partway through the playback.

Hi @Dominic ,

No problem, I will continue to discuss with the Support team and come back to you as soon as I can.

Meanwhile, the Created upstream selection method has been fixed and patched! Updating to the latest patch version on your application will fix this selection method for use.

Hope this helps :slight_smile: