Fixed test break.

This commit is contained in:
Qiang Xue 2014-02-13 21:18:43 -05:00
parent dd0a8defbf
commit d9ff05cb75
4 changed files with 4 additions and 4 deletions

View File

@ -17,6 +17,6 @@ class ContactPage extends BasePage
$inputType = $field === 'body' ? 'textarea' : 'input'; $inputType = $field === 'body' ? 'textarea' : 'input';
$this->guy->fillField($inputType . '[name="ContactForm[' . $field . ']"]', $value); $this->guy->fillField($inputType . '[name="ContactForm[' . $field . ']"]', $value);
} }
$this->guy->click('#contact-form button[type=submit]'); $this->guy->click('contact-button');
} }
} }

View File

@ -16,6 +16,6 @@ class LoginPage extends BasePage
{ {
$this->guy->fillField('input[name="LoginForm[username]"]', $username); $this->guy->fillField('input[name="LoginForm[username]"]', $username);
$this->guy->fillField('input[name="LoginForm[password]"]', $password); $this->guy->fillField('input[name="LoginForm[password]"]', $password);
$this->guy->click('#login-form button[type=submit]'); $this->guy->click('login-button');
} }
} }

View File

@ -48,7 +48,7 @@ $this->params['breadcrumbs'][] = $this->title;
'template' => '<div class="row"><div class="col-lg-3">{image}</div><div class="col-lg-6">{input}</div></div>', 'template' => '<div class="row"><div class="col-lg-3">{image}</div><div class="col-lg-6">{input}</div></div>',
]) ?> ]) ?>
<div class="form-group"> <div class="form-group">
<?= Html::submitButton('Submit', ['class' => 'btn btn-primary']) ?> <?= Html::submitButton('Submit', ['class' => 'btn btn-primary', 'name' => 'contact-button']) ?>
</div> </div>
<?php ActiveForm::end(); ?> <?php ActiveForm::end(); ?>
</div> </div>

View File

@ -34,7 +34,7 @@ $this->params['breadcrumbs'][] = $this->title;
<div class="form-group"> <div class="form-group">
<div class="col-lg-offset-1 col-lg-11"> <div class="col-lg-offset-1 col-lg-11">
<?= Html::submitButton('Login', ['class' => 'btn btn-primary']) ?> <?= Html::submitButton('Login', ['class' => 'btn btn-primary', 'name' => 'login-button']) ?>
</div> </div>
</div> </div>