Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prompt for collaborator generation when type hint is wrongly namespaced #1351

Open
ciaranmcnulty opened this issue Dec 10, 2020 · 0 comments
Labels

Comments

@ciaranmcnulty
Copy link
Member

If a user forgets to use a namespace for their dependency when type hinting it:

namespace spec\MyProject

class FooSpec extends ObjectBehaviour
{
    function it_does_a_thing(Collab $collab)
    {

    }
}

Currently we detect that it starts with the spec namespace and silently ignore it.

It would be better to alert the user what's going on (maybe some sort of better error message?), or even better prompt them and change the namespace in the spec file on their behalf

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant