Skip to content

Commit

Permalink
laravel 5.5.x support
Browse files Browse the repository at this point in the history
  • Loading branch information
DarkaOnLine committed Aug 31, 2017
1 parent 01f8e2e commit 8827acb
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 3 deletions.
1 change: 1 addition & 0 deletions README.md
Expand Up @@ -23,6 +23,7 @@ For Swagger 2.0
5.3.x | 2.2 | 1.1, 1.2, 2.0 | ```php composer require "darkaonline/l5-swagger:~3.0" ```
5.4.x | 2.2 | 1.1, 1.2, 2.0 | ```php composer require "darkaonline/l5-swagger:~4.0" ```
5.4.x | 3 | 2.0 | ```php composer require "darkaonline/l5-swagger:5.4.*" ```
5.5.x | 3 | 2.0 | ```php composer require "darkaonline/l5-swagger:5.5.*" ```


For Swagger 1.0
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Expand Up @@ -22,7 +22,7 @@
"require-dev": {
"phpunit/phpunit": "6.*",
"mockery/mockery": "0.9.*",
"orchestra/testbench": "~3.4",
"orchestra/testbench": "3.5.*",
"satooshi/php-coveralls": "^1.0"
},
"autoload": {
Expand Down
5 changes: 5 additions & 0 deletions src/helpers.php
Expand Up @@ -6,7 +6,10 @@
/**
* Returns swagger-ui composer dist path.
*
* @param null $asset
*
* @return string
* @throws \L5Swagger\Exceptions\L5SwaggerException
*/
function swagger_ui_dist_path($asset = null)
{
Expand Down Expand Up @@ -43,7 +46,9 @@ function swagger_ui_dist_path($asset = null)
* Returns asset from swagger-ui composer package.
*
* @param $asset string
*
* @return string
* @throws \L5Swagger\Exceptions\L5SwaggerException
*/
function l5_swagger_asset($asset)
{
Expand Down
4 changes: 2 additions & 2 deletions tests/TestCase.php
Expand Up @@ -66,11 +66,11 @@ protected function setCustomDocsFileName($fileName)
protected function copyAssets()
{
$src = __DIR__.'/../vendor/swagger-api/swagger-ui/dist/';
$destination = __DIR__.'/../vendor/orchestra/testbench-core/fixture/vendor/swagger-api/swagger-ui/dist/';
$destination = __DIR__.'/../vendor/orchestra/testbench-core/laravel/vendor/swagger-api/swagger-ui/dist/';

if (! is_dir($destination)) {
$base = realpath(
__DIR__.'/../vendor/orchestra/testbench-core/fixture/vendor'
__DIR__.'/../vendor/orchestra/testbench-core/laravel/vendor'
);

mkdir($base = $base.'/swagger-api');
Expand Down

0 comments on commit 8827acb

Please sign in to comment.