示例#1
0
 /**
  * Displays information about the given Document
  *
  * @param Document $document
  * @param bool $showBody
  */
 public function showDocument(Document $document, $showBody = FALSE)
 {
     $this->outputLine(static::ESCAPE . static::GREEN . 'Database: ' . $document->_getDb() . ' ' . 'ID: ' . ($document->getId() ? $document->getId() : '(Missing ID)') . ' ' . static::ESCAPE . static::NORMAL);
     if ($showBody) {
         $this->outputLine($this->formatJsonData($document->_getDataProtected(), TRUE) . PHP_EOL);
     }
 }
示例#2
0
 /**
  * @test
  */
 public function getInitialContentTest()
 {
     $model = new Document();
     $result = $model->_getDataProtected();
     $this->assertNull($result);
 }