skip to content

In a managed test case repository, how does comparing two revisions of a case differ from restoring one, and what does a restore leave behind in the trail?

level: middleimportance: must knowfreq 55%

answer

  1. compare reads, restore writes
  2. a restore is a new revision, not a rewind
  3. attributed to whoever pressed it, dated now
  4. nothing in between is deleted; the trail only grows

basics

~20 s

Comparing two revisions is a read-only, field-by-field diff. Restoring writes the old values back as a brand-new revision attributed to you, now — it never deletes the revisions in between, so the trail only grows.

solid answer

~40 s

A comparison picks two revisions and shows, field by field, what differs between them. It writes nothing, and anyone with view rights can run it. A restore is an ordinary edit that happens to take its values from an older revision: the repository copies those values onto the live case and appends a new revision whose actor is you and whose timestamp is now. Nothing is rewound — the revisions you restored past stay in the trail, which is precisely what keeps the history auditable. Two limits bite in practice. A restore usually covers only the versioned fields, so attachments, links and comments are not carried back with them; and restoring is often a separate permission from editing, held by fewer people.

go deeper

for a junior

Know the two actions apart: a comparison shows the difference between two revisions and changes nothing, while a restore puts older values back onto the live case as a real edit.

for a middle

Explain that a restore is a forward write — new revision, your name, the current timestamp — and state clearly that the revisions in between survive untouched.

for a senior

Cover the edges: what a restore does not carry back, whether restoring is gated by its own permission, and how you record a reason so the next reader understands why the text moved backwards.

for a principal

Argue the design principle. An append-only trail is more valuable than a tidy one, so resist requests to make a restore look like the intervening edits never happened.

Every managed case repository that keeps a per-field change history offers two operations on top of it, and candidates routinely conflate them. One is a **read** across two points in the trail. The other is a **write** whose values happen to come from the past. Getting the difference right also settles the question interviewers really care about: what a restore does to the record. ## Comparing: a read across two points A comparison names two revisions of the same case and renders the difference between them field by field: the title then and now, the preconditions then and now, and so on. Three properties matter. - It **changes nothing**. Running it a hundred times leaves the case and the trail exactly as they were, and it adds no entry of its own. - It is normally available to **anyone who can read the case**, because reading two stored states is not a privileged act. - It is **derived, not stored**. The product computes it from the entries; there is no comparison object sitting anywhere. The one place comparison misleads is the same place the underlying entries are thin. If step edits are journaled as a bare marker rather than as per-row before-and-after text, the comparison inherits that thinness — it will tell you the steps differ without telling you how. ## Restoring: a write that points backwards A restore reads an older revision, takes its values, and **saves them onto the live case as a new edit**. That is the whole mechanism, and every consequence follows from it: 1. **A new revision is appended.** Its actor is whoever pressed restore, and its timestamp is the moment of the restore — not the original author, not the original date. 2. **Its rows read backwards.** The before values are today's text; the after values are the old text. Someone reading the trail later sees a normal edit that happens to move the fields back. 3. **Nothing between is removed.** Every revision you restored past is still there in order. The trail is longer after a restore than before it, never shorter. | | Compare | Restore | |---|---|---| | Effect on the case | None | Live fields are overwritten with old values | | Effect on the trail | None | One new revision appended | | Attributed to | Nobody | The person who restored, at the current time | | Typical permission | View | Edit, sometimes a distinct restore right | ## What a restore does not bring back This is where the mechanism disappoints people who expected a time machine. A restore covers **versioned fields** and generally nothing else: - **Attachments** are usually not restored with the text — the trail records that a file was added or removed, not the bytes to put back. - **Comments and discussion** are their own stream, not case fields, so they are untouched. - **Anything the case merely points at** — a shared step definition, a referenced dataset, a linked tracker item — keeps whatever value it has today. Restoring the case's own text does not reach through those references. So a restored case can be a faithful copy of the old wording and still not be the old case in every respect. Say that out loud in an interview; it is the detail that separates someone who has used a restore from someone who has read about one. ## Permissions and etiquette Because a restore silently replaces the current text of a shared artefact, products commonly gate it more tightly than ordinary editing, and teams add convention on top: - Leave a **reason** — a comment on the case, or a note in whatever your team reads — because the revision itself records only what moved, never why. - Prefer restoring **into a visible moment**, not quietly at the end of a day, when other people may be working from the current wording. - Check for concurrent edits first: a restore is a full overwrite of the fields it covers, so an edit someone else made minutes ago disappears from the live case even though it survives in the trail. ## Why append-only is the point Occasionally someone asks for the tidy version: restore the case and make the intervening revisions go away, so the history reads as though the bad edit never happened. Refuse it. A trail is worth something only because entries cannot be removed by the people whose work they describe. The moment a revision can be deleted, no revision proves anything, and every earlier answer the history gave becomes unreliable. Fix forward — the correction is another entry, and the entry that was wrong stays visible above it.

  • After a restore, how would you tell from the history alone that the current text came from an older revision?
    The newest revision shows today's actor moving fields to values that already appear earlier in the trail — the same wording turning up twice, separated by other edits. Some products annotate restores explicitly; most do not, so a note left on the case at the time is what makes it obvious to the next reader.
  • Someone asks you to delete an embarrassing revision from a case's history. What do you say?
    No, and explain why: the trail is credible only because entries cannot be removed by the people they describe. Removing one devalues every other entry. Correct it forward with a new revision, and if the content itself is genuinely sensitive, escalate it as an administrative matter rather than quietly editing the record.

It behaves like the version history of a shared document: restoring an older version does not erase the versions in between, it copies the old text forward as the newest one, with your name and today's date on it.

saying these in an interview costs you the question

  • Thinks restoring deletes the revisions made after it
  • Expects a restore to be attributed to the original author
  • Assumes attachments and links come back with a restored revision
  • Treats the compare view as an edit to the case
  • Believes a restore rolls back without creating a new entry