Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
69.23% covered (warning)
69.23%
9 / 13
50.00% covered (danger)
50.00%
1 / 2
CRAP
0.00% covered (danger)
0.00%
0 / 1
AppServiceProvider
69.23% covered (warning)
69.23%
9 / 13
50.00% covered (danger)
50.00%
1 / 2
2.12
0.00% covered (danger)
0.00%
0 / 1
 register
66.67% covered (warning)
66.67%
8 / 12
0.00% covered (danger)
0.00%
0 / 1
1.04
 boot
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
1<?php
2
3namespace App\Providers;
4
5use Illuminate\Support\ServiceProvider;
6
7class AppServiceProvider extends ServiceProvider
8{
9    /**
10     * Register any application services.
11     *
12     * @return void
13     */
14    public function register(): void
15    {
16        app()->singleton('urlToDocs', function () {
17            return env('APP_URL') . '/docs/api-docs.json';
18        });
19
20        app()->singleton('swaggeruibundle', function () {
21            return env('APP_URL') . '/docs/asset/swagger-ui-bundle.js';
22        });
23
24        app()->singleton('swaggeruistandalonepreset', function () {
25            return env('APP_URL') . '/docs/asset/swagger-ui-standalone-preset.js';
26        });
27
28        app()->singleton('swagger-ui', function () {
29            return env('APP_URL') . '/docs/asset/swagger-ui.css';
30        });
31    }
32
33    /**
34     * Bootstrap any application services.
35     *
36     * @return void
37     */
38    public function boot()
39    {
40        //
41    }
42}