Examples
A version bump
Input
release=1
release=2Expected checks
Case-insensitiveContains "<del>1</del>"
Contains "<ins>2</ins>"- Sample delimiter
- Diff by
Word- Show added
On- Show removed
On- Show subtraction
Off- Ignore whitespace
Off
A corrected setting
Input
cache off
cache onExpected checks
Case-insensitiveContains "<del>off</del>"
Contains "<ins>on</ins>"- Sample delimiter
- Diff by
Word- Show added
On- Show removed
On- Show subtraction
Off- Ignore whitespace
Off
A renamed file
Input
old.json
new.jsonExpected checks
Case-insensitiveContains "<del>old</del>"
Contains "<ins>new</ins>"- Sample delimiter
- Diff by
Word- Show added
On- Show removed
On- Show subtraction
Off- Ignore whitespace
Off
A changed unit
Input
distance miles
distance metresExpected checks
Case-insensitiveContains "<del>miles</del>"
Contains "<ins>metres</ins>"- Sample delimiter
- Diff by
Word- Show added
On- Show removed
On- Show subtraction
Off- Ignore whitespace
Off
A corrected word
Input
hello work
hello worldExpected checks
Case-insensitiveContains "<del>work</del>"
Contains "<ins>world</ins>"- Sample delimiter
- Diff by
Word- Show added
On- Show removed
On- Show subtraction
Off- Ignore whitespace
Off
Diff added with subtraction, basic usage
Input
testing23
testing123Expected answer
<ins>1</ins>- Sample delimiter
\n\n- Diff by
Character- Show added
On- Show removed
On- Show subtraction
On- Ignore whitespace
Off
Diff removed with subtraction, basic usage
Input
testing123
testing3Expected answer
<del>12</del>- Sample delimiter
\n\n- Diff by
Character- Show added
On- Show removed
On- Show subtraction
On- Ignore whitespace
Off
Diff, basic usage
Input
testing23
testing123Expected answer
testing<ins>1</ins>23- Sample delimiter
\n\n- Diff by
Character- Show added
On- Show removed
On- Show subtraction
Off- Ignore whitespace
Off
Format reference: Diff background and specification
Parameters
| Parameter | Default value | Input and choices |
|---|---|---|
| Sample delimiter | "\\n\\n" | Escape sequences such as \n, \r and \t are supported |
| Diff by | Character | Character, Word, Line, Sentence, CSS, JSON |
| Show added | true | On or off |
| Show removed | true | On or off |
| Show subtraction | false | On or off |
| Ignore whitespace | false | Applies to word and line comparisons. |