public function test_get_cache_path_method()
 {
     $abPath = 'bootstrap/cache/eloquent.php';
     $path = EloquentCacheCommand::getCachedEloquentPath();
     $replaced = str_replace($abPath, '', $path);
     $this->assertNotEquals($replaced, $path);
 }
 /**
  * Try loading eloquent cache
  *
  * @return void
  */
 protected function tryLoadingEloquentCache()
 {
     $this->app->booted(function () {
         $array = (array) @(include_once EloquentCacheCommand::getCachedEloquentPath());
         if (!empty($array)) {
             FasterModel::loadArrayIntoCachedMutatorAttributes($array);
         }
     });
 }
 /**
  * Execute the console command.
  *
  * @return mixed
  */
 public function handle()
 {
     $this->info("Starting to clear cache...");
     if ($this->files->exists($path = EloquentCacheCommand::getCachedEloquentPath())) {
         $this->files->delete($path);
         $this->info("Cache cleared.");
     } else {
         $this->comment("No cache to clear.");
     }
 }