Exemplo n.º 1
0
 public function testLastModified()
 {
     $parser = new Parser();
     $lastModified = $parser->getLastModified();
     // let's verify the date format
     $parsed = DateTime::createFromFormat('M jS (D)', $lastModified);
     $this->assertEquals($parsed->format('M jS (D)'), $lastModified);
 }
Exemplo n.º 2
0
<?php

use Paplauskas\ApiDocs\Parser;
Route::get('apidocs', function () {
    $parser = new Parser();
    return view('apidocs::index', ['lastModified' => $parser->getLastModified(), 'endpoints' => $parser->parseEndpoints()]);
});