0
votes

Trying to implement the behat-page-object-extension and when running behat I get the following error: Fatal error: Uncaught ArgumentCountError: Too few arguments to function FeatureContext::__construct()

Github for the project -> https://github.com/andrew0071/MyBehatProject

composer.json

enter image description here

behat.yml

enter image description here

Homepage.php

enter image description here

FeatureContext.php

Injecting page objects into a context file Page objects will be injected directly into a context file if they’re defined as constructor arguments with a type hint: enter image description here

test.feature.php

enter image description here

When running the test

enter image description here

1

1 Answers

0
votes

Your behat.yml is all messed up. Indentation in YAML matters.