yii2-netdisk/tests/_pages/ContactPage.php

23 lines
381 B
PHP
Raw Normal View History

2013-12-02 15:25:21 +04:00
<?php
namespace tests\_pages;
use yii\codeception\BasePage;
2013-12-02 15:25:21 +04:00
class ContactPage extends BasePage
{
2013-12-17 23:43:43 -05:00
public $route = 'site/contact';
2013-12-02 15:25:21 +04:00
/**
* @param array $contactData
*/
public function submit(array $contactData)
{
2013-12-28 19:26:18 -05:00
$data = [];
foreach ($contactData as $name => $value) {
$data["ContactForm[$name]"] = $value;
2013-12-02 15:25:21 +04:00
}
2013-12-28 19:26:18 -05:00
$this->guy->submitForm('#contact-form', $data);
2013-12-02 15:25:21 +04:00
}
}