Join 34,000+ subscribers and receive articles from our blog about software quality, testing, QA and security.

Updating timestamp of when Test Run was created


I’d like to be able to update the timestamp of when a test run was created, so that it will move to the top of the list of test runs in TestRail. I see there’s a “created_on” field in the test run JSON object, so I’ve been trying to work with that, but so far no luck. Here’s what I have:

testRunID = ConfigFactory.load.getString("my.testrail.TestRunID")
val data = new java.util.HashMap[String, Timestamp]()
data.put("created_on", new java.sql.Timestamp(System.currentTimeMillis()))
val path = "update_run/" + testRunID
client.sendPost(path, data)



Hi Mike,

Thanks for your posting! The creation date/time is determined by TestRail when you add the run via add_run or add_plan. Updating the creation date afterwards is not possible (neither with the UI or API) and this would be the standard behavior for most applications. Depending on your requirements, you can also change the grouping/sort order to something else (in the sidebar on Test Runs & Results), e.g. the name of the runs and this would be the most flexible option.

I hope this helps!