示例#1
0
 public function it_converts_original_line_to_modified_line_when_getting_a_single_line()
 {
     $original = new OriginalLineNumber(3);
     $modified = new ModifiedLineNumber(8);
     $this->lineTracker->trackLine($original)->willReturn($modified);
     $this->modified->getLines(LineRange::createSingleLine(8))->shouldBeCalled()->willReturn(array());
     $this->getLine($original);
 }
示例#2
0
 /**
  * @return string
  */
 public function getLine($lineNumber)
 {
     $lineNumber = $this->convertIfIsOriginalLineNumber($lineNumber);
     $lines = $this->modified->getLines(LineRange::createSingleLine($lineNumber->getNumber()));
     return reset($lines);
 }