Nwidart\Modules\Repository::getUsedStoragePath PHP Method

getUsedStoragePath() public method

Get storage path for module used.
public getUsedStoragePath ( ) : string
return string
    public function getUsedStoragePath()
    {
        if (!$this->app['files']->exists($path = storage_path('app/modules'))) {
            $this->app['files']->makeDirectory($path, 0777, true);
        }
        return $path . '/modules.used';
    }

Usage Example

 /** @test */
 public function it_gets_the_used_storage_path()
 {
     $path = $this->repository->getUsedStoragePath();
     $this->assertEquals(storage_path('app/modules/modules.used'), $path);
 }