0
任何人都可以從根文件夾提供Yii2中的Codeception運行命令嗎?我試圖運行yii2中的codeception的命令
vendor/bin/codecept run 'patt/to/testfile'
,但它不工作。
任何人都可以從根文件夾提供Yii2中的Codeception運行命令嗎?我試圖運行yii2中的codeception的命令
vendor/bin/codecept run 'patt/to/testfile'
,但它不工作。
必須配置的路徑,其中配置文件位於:
vendor/bin/codeception run -c /path/to/config.yml testsuitename /path/to/testfile
HTH
默認情況下,您的配置文件codeception.yml
位於tests
。因此,您可以運行命令爲
vendor/bin/codecept run -c tests/ testsuitename path/to/testfile
謝謝。現在,我得到了致命的錯誤:運行單元測試時未找到類。似乎是命名空間的問題?或與引導文件配置? – sapo
現在工作正常。 vendor/bin/codeception運行testsuitename/path/to/testfile爲我工作。謝謝 – sapo