replaceTextRange(range, text) {
		let actualRange;

		if (this.retainedRange) {
			actualRange = [
				Math.min(this.retainedRange[0], range[0]),
				Math.max(this.retainedRange[1], range[1]),
			];
		} else {
			actualRange = range;
		}

		return this.fixer.replaceTextRange(
			actualRange,
			this.sourceCode.text.slice(actualRange[0], range[0]) +
				text +
				this.sourceCode.text.slice(range[1], actualRange[1]),
		);
	}
Create a fix command that replaces the given range with the given text,
accounting for any retained ranges.
@param {SourceRange} range The range to remove in the fix.
@param {string} text The text to insert in place of the range.
@returns {Object} The fix command.