1
我正在嘗試確定如何通過必需的參數來遵循我的Behat功能文件中定義的路徑。在我的Behat場景中通過必需的參數
這是我的情景:
Scenario: I should be able to create a cars asset
Given I am on the ayrshireminis_cars_asset_create page
When I submit a "ayrshireminis.cars.asset.type" form with values:
| name | type | position | active |
| Cars Info Doc | PDF | 1 | 1 |
Then The form should be valid
,這是錯誤:
Given I am on the ayrshireminis_cars_asset_create page Some mandatory parameters are missing ("categoryId") to generate a URL for route "ayrshireminis_cars_asset_create". (Symfony\Component\Routing\Exception\MissingMandatoryParametersException)
很清楚,爲什麼我得到這個錯誤我的路由配置是這樣的:
ayrshireminis_cars_asset_create:
pattern: /category/{categoryId}/asset/new/
如何通過categoryId
?