受け入れテストに codeception を使用しようとしています。Selenium2で使用することにしました。開始環境:
受け入れ.suite.yml:
class_name: WebGuy
modules:
enabled:
- Selenium2
- WebHelper
config:
Selenium2:
url: 'http://nemo.dev'
browser: firefox
delay: 1000
テスト:
<?php
$I = new WebGuy($scenario);
$I->wantTo('see text');
$I->amGoingTo('/');
$I->see('text');
ビルドして実行すると、Firefox が起動し、空白のページが表示されて終了します。
コンソールで:
1) Couldn't see text in SigninCept.php
Guy couldn't see "text": 'text' in .
Failed asserting that response contains "text". Response was saved to 'log' directory.
Scenario Steps:
2. I see "text"
1. I am going to /
FAILURES!
Tests: 1, Assertions: 1, Failures: 1.
Mac OS X 10.8.3、selenium を実行: selenium-server-standalone-2.32.0.jar、PHP 5.3.15。失敗、ログに白い画面のスクリーンショット、状況が理解できない。