+--------------------------------------------------------------------+
| CiviCRM version 4.6 |
+--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2014 |
+ | Copyright CiviCRM LLC (c) 2004-2015 |
+--------------------------------------------------------------------+
| This file is a part of CiviCRM. |
| |
$this->type("xpath=//input[@id='price_{$textFieldId}']", '1');
// select sold option for select field, check for form rule
- $this->select("price_{$selectFieldId}", "value={$selectFieldOp1}");
- $this->click('_qf_Register_upload-bottom');
- $this->waitForPageToLoad($this->getTimeoutMsec());
-
- $this->assertStringsPresent(array('Sorry, this option is currently sold out.'));
+ $this->assertElementContainsText("xpath=//select[@id='price_{$selectFieldId}']//option[@value='crm_disabled_opt-{$selectFieldOp1}']", "(Sold out)");
// fill correct available option for select field
$this->select("price_{$selectFieldId}", "value={$selectFieldOp2}");
$this->type("xpath=//input[@id='price_{$textFieldId}']", '1');
// check for sold option for select field
- $this->select("price_{$selectFieldId}", "value={$selectFieldOp1}");
-
- $this->click('_qf_Register_upload-bottom');
- $this->waitForPageToLoad($this->getTimeoutMsec());
-
- $this->assertStringsPresent(array('Sorry, this option is currently sold out.'));
+ $this->assertElementContainsText("xpath=//select[@id='price_{$selectFieldId}']//option[@value='crm_disabled_opt-{$selectFieldOp1}']", "(Sold out)");
// check for sold option for select field
$this->select("price_{$selectFieldId}", "value={$selectFieldOp2}");
$this->type("xpath=//input[@id='price_{$textFieldId}']", '1');
// check for select
- $this->select("price_{$selectFieldId}", "value={$selectFieldOp2}");
-
- $this->click('_qf_Participant_2_next-Array');
- $this->waitForPageToLoad($this->getTimeoutMsec());
-
- $this->assertStringsPresent(array('Sorry, currently only 2 seats are available for this option.'));
+ $this->assertElementContainsText("xpath=//select[@id='price_{$selectFieldId}']//option[@value='crm_disabled_opt-{$selectFieldOp2}']", "(Sold out)");
// Skip participant3 and register
$this->click('_qf_Participant_2_next_skip-Array');
$this->type("xpath=//input[@id='price_{$textFieldId}']", '1');
// check for select field
- $this->select("price_{$selectFieldId}", "value={$selectFieldOp2}");
-
- $this->click('_qf_Register_upload-bottom');
- $this->waitForPageToLoad($this->getTimeoutMsec());
-
- $this->assertStringsPresent(array('Sorry, this option is currently sold out.'));
+ $this->assertElementContainsText("xpath=//select[@id='price_{$selectFieldId}']//option[@value='crm_disabled_opt-{$selectFieldOp2}']", "(Sold out)");
// fill available value for select
$this->select("price_{$selectFieldId}", "value={$selectFieldOp1}");
$this->type("xpath=//input[@id='price_{$textFieldId}']", '1');
// check for select field
- $this->select("price_{$selectFieldId}", "value={$selectFieldOp2}");
-
- $this->click('_qf_Participant_1_next-Array');
- $this->waitForPageToLoad($this->getTimeoutMsec());
-
- $this->assertStringsPresent(array('Sorry, this option is currently sold out.'));
+ $this->assertElementContainsText("xpath=//select[@id='price_{$selectFieldId}']//option[@value='crm_disabled_opt-{$selectFieldOp2}']", "(Sold out)");
// fill available value for select
$this->select("price_{$selectFieldId}", "value={$selectFieldOp1}");
$this->type("xpath=//input[@id='price_{$textFieldId}']", '1');
// check for select
- $this->select("price_{$selectFieldId}", "value={$selectFieldOp2}");
-
- $this->click('_qf_Participant_2_next-Array');
- $this->waitForPageToLoad($this->getTimeoutMsec());
-
- $this->assertStringsPresent(array('Sorry, this option is currently sold out.'));
+ $this->assertElementContainsText("xpath=//select[@id='price_{$selectFieldId}']//option[@value='crm_disabled_opt-{$selectFieldOp2}']", "(Sold out)");
// Skip participant3 and register
$this->click('_qf_Participant_2_next_skip-Array');
$this->type("xpath=//input[@id='price_{$textFieldId}']", '1');
// check for select field
- $this->select("price_{$selectFieldId}", "value={$selectFieldOp2}");
-
- $this->click('_qf_Register_upload-bottom');
- $this->waitForPageToLoad($this->getTimeoutMsec());
-
- $this->assertStringsPresent(array('Sorry, this option is currently sold out.'));
+ $this->assertElementContainsText("xpath=//select[@id='price_{$selectFieldId}']//option[@value='crm_disabled_opt-{$selectFieldOp2}']", "(Sold out)");
// fill available value for select
$this->select("price_{$selectFieldId}", "value={$selectFieldOp1}");
$this->type("xpath=//input[@id='price_{$textFieldId}']", '1');
// check for select field
- $this->select("price_{$selectFieldId}", "value={$selectFieldOp2}");
-
- $this->click('_qf_Participant_1_next-Array');
- $this->waitForPageToLoad($this->getTimeoutMsec());
-
- $this->assertStringsPresent(array('Sorry, this option is currently sold out.'));
+ $this->assertElementContainsText("xpath=//select[@id='price_{$selectFieldId}']//option[@value='crm_disabled_opt-{$selectFieldOp2}']", "(Sold out)");
// fill available value for select
$this->select("price_{$selectFieldId}", "value={$selectFieldOp1}");
// Go to Fees tab
$this->click('link=Fees');
$this->waitForElementPresent('_qf_Fee_upload-bottom');
- $this->click('xpath=//form[@id="Fee"]/div[2]/table/tbody/tr[2]/td[2]/label[contains(text(), "Yes")]');
+ $this->click('xpath=//form[@id="Fee"]//div/table/tbody//tr//td/label[contains(text(), "Yes")]');
$processorName = $params['payment_processor'];
$this->click("xpath=//tr[@class='crm-event-manage-fee-form-block-payment_processor']/td[2]/label[text()='$processorName']");
$this->select('financial_type_id', 'value=4');
$this->click('is_multiple_registrations');
}
- $this->click('intro_text-plain');
- $this->fillRichTextField('intro_text', 'Fill in all the fields below and click Continue.');
+ $this->fillRichTextField('intro_text', 'Fill in all the fields below and click Continue.', 'CKEditor', TRUE);
// enable confirmation email
$this->click('CIVICRM_QFID_1_is_email_confirm');