I'm starting to work with phpspec and I'm struggling with this problem. I'm having a spec code like this :
class OrderItemSpec extends ObjectBehavior
{
function it_is_initializable()
{
$this->shouldHaveType('Ts\Project\Model\OrderItem');
}
function it_is_a_model()
{
$this->shouldImplement('Ts\Generic\Model');
}
}
Model interface class:
namespace Ts\Generic;
interface Model
{
}
When running phpspec it always ask me:
Do you want me to create `Ts\Generic\Model` for you?
File "Model.php" already exists. Overwrite?
When overwriting, he changes interface to a regular class.
In composer I have autoload configured like this :
"autoload": {
"psr-0": {
"": "src"
}
}
Is it a phpspec error, limitation or am I doing it in a wrong way ?