0

I already search it on Google for a while, and I found this article but the package that using for this article is not support Laravel 6, I want to use PHPSpec but I don't want to use older Laravel versions,

so I already tried using my PHPSpec yml config, but I'm not sure how to make it better for Laravel file structures.

Is there anyone that using Laravel 6 and know how to integrates with PHPSpec the correct way? so it'll be as close as possible with this article I found. Thanks!

EDIT

I just change the config, and here is the config now

phpspec.yml

suites:
  laravel_controller_suite:
    namespace: Servers
    src_path: app/Controllers
    spec_path: spec/Controllers
    spec_prefix: spec

  laravel_model_suite:
    namespace: Servers
    src_path: app/Models
    spec_path: spec/Models
    spec_prefix: spec

but when I execute phpspec describe Servers/Controllers/PageController

it's creates the directory to something like this,

enter image description here

how to fix it?

EDIT

My Laravel namespace is Servers

Amit Kumar PRO
  • 1,222
  • 2
  • 15
  • 27
  • Possible [here](https://laracasts.com/lessons/phpspec-laravel-and-refactoring) your solution? – Simone Rossaini Jan 07 '20 at 15:47
  • @SimoneRossaini Hi, thanks for the comment, but I already tried that, and I'm not sure how to make it the best way for Laravel 6, as the file structures is changed and I want to make it scalable as well. – Khrisna Gunanasurya Jan 07 '20 at 15:57

0 Answers0