ExecutableDifferenceReporter

public class ExecutableDifferenceReporter implements Reporter

A reporter that will shell out to an executable that is presented on the user’s machine to verify the test output. Note that the approval command and the difference commands can be the same.

  • approval command will be used for the first approval
  • the difference command will be used when there is already a verified file but it is not the same as the value from the user

Constructors

ExecutableDifferenceReporter

public ExecutableDifferenceReporter(String approvalCommand, String diffCommand)

Main constructor for the executable reporter.

Parameters:
  • approvalCommand – the approval command
  • diffCommand – the difference command

Methods

approveNew

public boolean approveNew(byte[] value, File approvalDestination, File fileForVerification)

canApprove

public boolean canApprove(File fileForApproval)

notTheSame

public void notTheSame(byte[] oldValue, File fileForVerification, byte[] newValue, File fileForApproval)

startProcess

Process startProcess(String... cmdParts)