I use the really cool knplabs/friendlycontexts bundle to test VictoireDCMS, a Symfony2 open source DCMS.
Actually, this is working pretty well in spite of the kind of my project (not a basic symfony-project architecture but a suite of bundles with a functionnal test application).
But... I'm now blocked to use alice reference in the EntityContext. The documentation give these examples :
user.yml
App\Entity\User:
user-john:
firstname: John
lastname: Doe
user-admin:
firstname: Admin
lastname: Admin
my.feature
@alice(User)
Feature: My feature
The feature description
Background:
Given the following products
| name | user |
| Ball | John |
| Shoes | Admin |
...
This is really looking good and is exactly what I want to do and here is my code:
template.yml (full file)
Victoire\Bundle\TemplateBundle\Entity\Template:
template_base:
name: Base
...
my.feature (full file)
Given the following page:
| name | slug | locale | template |
| tatooine | tatooine | fr | base |
Unfortunatelly, it doesn't work properly and I have this error when I run my feature :
Expected value of type "Victoire\Bundle\TemplateBundle\Entity\Template" for association field "Victoire\Bundle\PageBundle\Entity\BasePage#$template", got "string" instead. (Doctrine\ORM\ORMInvalidArgumentException)
I can't figure this out and can't see any difference btw the example and my code... Any help would be appreciated.