Commit 29967330 authored by Tobias Munk's avatar Tobias Munk

updated tests

parent f26579a9
Pipeline #11025 failed with stages
in 14 seconds
<?php //[STAMP] 19caea571d7efb9db4bc77af7ecb17cd
<?php //[STAMP] 6ce3cc226e84d9c7716ef98ce73cd510
namespace _generated;
// This class was automatically generated by build task
......@@ -673,8 +673,8 @@ trait FunctionalTesterActions
* [!] Method is generated. Documentation taken from corresponding module.
*
* Checks that the current page contains the given string (case insensitive).
*
* You can specify a specific HTML element (via CSS or XPath) as the second
*
* You can specify a specific HTML element (via CSS or XPath) as the second
* parameter to only search within that element.
*
* ``` php
......@@ -683,19 +683,19 @@ trait FunctionalTesterActions
* $I->see('Sign Up', 'h1'); // I can suppose it's a signup page
* $I->see('Sign Up', '//body/h1'); // with XPath
* ```
*
*
* Note that the search is done after stripping all HTML tags from the body,
* so `$I->see('strong')` will return true for strings like:
*
*
* - `<p>I am Stronger than thou</p>`
* - `<script>document.createElement('strong');</script>`
*
*
* But will *not* be true for strings like:
*
*
* - `<strong>Home</strong>`
* - `<div class="strong">Home</strong>`
* - `<!-- strong -->`
*
*
* For checking the raw source code, use `seeInSource()`.
*
* @param $text
......@@ -710,8 +710,8 @@ trait FunctionalTesterActions
* [!] Method is generated. Documentation taken from corresponding module.
*
* Checks that the current page contains the given string (case insensitive).
*
* You can specify a specific HTML element (via CSS or XPath) as the second
*
* You can specify a specific HTML element (via CSS or XPath) as the second
* parameter to only search within that element.
*
* ``` php
......@@ -720,19 +720,19 @@ trait FunctionalTesterActions
* $I->see('Sign Up', 'h1'); // I can suppose it's a signup page
* $I->see('Sign Up', '//body/h1'); // with XPath
* ```
*
*
* Note that the search is done after stripping all HTML tags from the body,
* so `$I->see('strong')` will return true for strings like:
*
*
* - `<p>I am Stronger than thou</p>`
* - `<script>document.createElement('strong');</script>`
*
*
* But will *not* be true for strings like:
*
*
* - `<strong>Home</strong>`
* - `<div class="strong">Home</strong>`
* - `<!-- strong -->`
*
*
* For checking the raw source code, use `seeInSource()`.
*
* @param $text
......@@ -756,19 +756,19 @@ trait FunctionalTesterActions
* $I->dontSee('Sign Up','h1'); // I can suppose it's not a signup page
* $I->dontSee('Sign Up','//body/h1'); // with XPath
* ```
*
*
* Note that the search is done after stripping all HTML tags from the body,
* so `$I->dontSee('strong')` will fail on strings like:
*
*
* - `<p>I am Stronger than thou</p>`
* - `<script>document.createElement('strong');</script>`
*
*
* But will ignore strings like:
*
*
* - `<strong>Home</strong>`
* - `<div class="strong">Home</strong>`
* - `<!-- strong -->`
*
*
* For checking the raw source code, use `seeInSource()`.
*
* @param $text
......@@ -791,19 +791,19 @@ trait FunctionalTesterActions
* $I->dontSee('Sign Up','h1'); // I can suppose it's not a signup page
* $I->dontSee('Sign Up','//body/h1'); // with XPath
* ```
*
*
* Note that the search is done after stripping all HTML tags from the body,
* so `$I->dontSee('strong')` will fail on strings like:
*
*
* - `<p>I am Stronger than thou</p>`
* - `<script>document.createElement('strong');</script>`
*
*
* But will ignore strings like:
*
*
* - `<strong>Home</strong>`
* - `<div class="strong">Home</strong>`
* - `<!-- strong -->`
*
*
* For checking the raw source code, use `seeInSource()`.
*
* @param $text
......@@ -1425,7 +1425,7 @@ trait FunctionalTesterActions
*
* Checks if the array of form parameters (name => value) are set on the form matched with the
* passed selector.
*
*
* ``` php
* <?php
* $I->seeInFormFields('form[name=myform]', [
......@@ -1434,10 +1434,10 @@ trait FunctionalTesterActions
* ]);
* ?>
* ```
*
*
* For multi-select elements, or to check values of multiple elements with the same name, an
* array may be passed:
*
*
* ``` php
* <?php
* $I->seeInFormFields('.form-class', [
......@@ -1454,7 +1454,7 @@ trait FunctionalTesterActions
* ```
*
* Additionally, checkbox values can be checked with a boolean.
*
*
* ``` php
* <?php
* $I->seeInFormFields('#form-id', [
......@@ -1463,9 +1463,9 @@ trait FunctionalTesterActions
* ]);
* ?>
* ```
*
*
* Pair this with submitForm for quick testing magic.
*
*
* ``` php
* <?php
* $form = [
......@@ -1479,7 +1479,7 @@ trait FunctionalTesterActions
* $I->seeInFormFields('//form[@id=my-form]', $form);
* ?>
* ```
*
*
* @param $formSelector
* @param $params
* Conditional Assertion: Test won't be stopped on fail
......@@ -1493,7 +1493,7 @@ trait FunctionalTesterActions
*
* Checks if the array of form parameters (name => value) are set on the form matched with the
* passed selector.
*
*
* ``` php
* <?php
* $I->seeInFormFields('form[name=myform]', [
......@@ -1502,10 +1502,10 @@ trait FunctionalTesterActions
* ]);
* ?>
* ```
*
*
* For multi-select elements, or to check values of multiple elements with the same name, an
* array may be passed:
*
*
* ``` php
* <?php
* $I->seeInFormFields('.form-class', [
......@@ -1522,7 +1522,7 @@ trait FunctionalTesterActions
* ```
*
* Additionally, checkbox values can be checked with a boolean.
*
*
* ``` php
* <?php
* $I->seeInFormFields('#form-id', [
......@@ -1531,9 +1531,9 @@ trait FunctionalTesterActions
* ]);
* ?>
* ```
*
*
* Pair this with submitForm for quick testing magic.
*
*
* ``` php
* <?php
* $form = [
......@@ -1547,7 +1547,7 @@ trait FunctionalTesterActions
* $I->seeInFormFields('//form[@id=my-form]', $form);
* ?>
* ```
*
*
* @param $formSelector
* @param $params
* @see \Codeception\Lib\InnerBrowser::seeInFormFields()
......@@ -1562,7 +1562,7 @@ trait FunctionalTesterActions
*
* Checks if the array of form parameters (name => value) are not set on the form matched with
* the passed selector.
*
*
* ``` php
* <?php
* $I->dontSeeInFormFields('form[name=myform]', [
......@@ -1571,10 +1571,10 @@ trait FunctionalTesterActions
* ]);
* ?>
* ```
*
*
* To check that an element hasn't been assigned any one of many values, an array can be passed
* as the value:
*
*
* ``` php
* <?php
* $I->dontSeeInFormFields('.form-class', [
......@@ -1587,7 +1587,7 @@ trait FunctionalTesterActions
* ```
*
* Additionally, checkbox values can be checked with a boolean.
*
*
* ``` php
* <?php
* $I->dontSeeInFormFields('#form-id', [
......@@ -1596,7 +1596,7 @@ trait FunctionalTesterActions
* ]);
* ?>
* ```
*
*
* @param $formSelector
* @param $params
* Conditional Assertion: Test won't be stopped on fail
......@@ -1610,7 +1610,7 @@ trait FunctionalTesterActions
*
* Checks if the array of form parameters (name => value) are not set on the form matched with
* the passed selector.
*
*
* ``` php
* <?php
* $I->dontSeeInFormFields('form[name=myform]', [
......@@ -1619,10 +1619,10 @@ trait FunctionalTesterActions
* ]);
* ?>
* ```
*
*
* To check that an element hasn't been assigned any one of many values, an array can be passed
* as the value:
*
*
* ``` php
* <?php
* $I->dontSeeInFormFields('.form-class', [
......@@ -1635,7 +1635,7 @@ trait FunctionalTesterActions
* ```
*
* Additionally, checkbox values can be checked with a boolean.
*
*
* ``` php
* <?php
* $I->dontSeeInFormFields('#form-id', [
......@@ -1644,7 +1644,7 @@ trait FunctionalTesterActions
* ]);
* ?>
* ```
*
*
* @param $formSelector
* @param $params
* @see \Codeception\Lib\InnerBrowser::dontSeeInFormFields()
......@@ -1661,18 +1661,18 @@ trait FunctionalTesterActions
* values. Pass the form field's values as an array in the second
* parameter.
*
* Although this function can be used as a short-hand version of
* `fillField()`, `selectOption()`, `click()` etc. it has some important
* Although this function can be used as a short-hand version of
* `fillField()`, `selectOption()`, `click()` etc. it has some important
* differences:
*
*
* * Only field *names* may be used, not CSS/XPath selectors nor field labels
* * If a field is sent to this function that does *not* exist on the page,
* it will silently be added to the HTTP request. This is helpful for testing
* some types of forms, but be aware that you will *not* get an exception
* like you would if you called `fillField()` or `selectOption()` with
* a missing field.
*
* Fields that are not provided will be filled by their values from the page,
*
* Fields that are not provided will be filled by their values from the page,
* or from any previous calls to `fillField()`, `selectOption()` etc.
* You don't need to click the 'Submit' button afterwards.
* This command itself triggers the request to form's action.
......@@ -1735,10 +1735,10 @@ trait FunctionalTesterActions
* ```
* Note that "2" will be the submitted value for the "plan" field, as it is
* the selected option.
*
*
* You can also emulate a JavaScript submission by not specifying any
* buttons in the third parameter to submitForm.
*
*
* ```php
* <?php
* $I->submitForm(
......@@ -1752,10 +1752,10 @@ trait FunctionalTesterActions
* ]
* );
* ```
*
* This function works well when paired with `seeInFormFields()`
*
* This function works well when paired with `seeInFormFields()`
* for quickly testing CRUD interfaces and form validation logic.
*
*
* ``` php
* <?php
* $form = [
......@@ -1796,11 +1796,11 @@ trait FunctionalTesterActions
*
* Mixing string and boolean values for a checkbox's value is not supported
* and may produce unexpected results.
*
* Field names ending in `[]` must be passed without the trailing square
*
* Field names ending in `[]` must be passed without the trailing square
* bracket characters, and must contain an array for its value. This allows
* submitting multiple values with the same name, consider:
*
*
* ```php
* <?php
* // This will NOT work correctly
......@@ -1809,9 +1809,9 @@ trait FunctionalTesterActions
* 'field[]' => 'another value', // 'field[]' is already a defined key
* ]);
* ```
*
*
* The solution is to pass an array value:
*
*
* ```php
* <?php
* // This way both values are submitted
......@@ -1822,7 +1822,7 @@ trait FunctionalTesterActions
* ]
* ]);
* ```
*
*
* @param $selector
* @param $params
* @param $button
......@@ -2027,7 +2027,8 @@ trait FunctionalTesterActions
* [!] Method is generated. Documentation taken from corresponding module.
*
* Finds and returns the text contents of the given element.
* If a fuzzy locator is used, the element is found using CSS, XPath, and by matching the full page source by regular expression.
* If a fuzzy locator is used, the element is found using CSS, XPath,
* and by matching the full page source by regular expression.
*
* ``` php
* <?php
......@@ -2076,23 +2077,23 @@ trait FunctionalTesterActions
*
* Grabs either the text content, or attribute values, of nodes
* matched by $cssOrXpath and returns them as an array.
*
*
* ```html
* <a href="#first">First</a>
* <a href="#second">Second</a>
* <a href="#third">Third</a>
* ```
*
*
* ```php
* <?php
* // would return ['First', 'Second', 'Third']
* $aLinkText = $I->grabMultiple('a');
*
*
* // would return ['#first', '#second', '#third']
* $aLinks = $I->grabMultiple('a', 'href');
* ?>
* ```
*
*
* @param $cssOrXpath
* @param $attribute
* @return string[]
......@@ -2507,9 +2508,15 @@ trait FunctionalTesterActions
*
* Checks that response code is equal to value provided.
*
* @param $code
* ```php
* <?php
* $I->seeResponseCodeIs(200);
*
* @return mixed
* // recommended \Codeception\Util\HttpCode
* $I->seeResponseCodeIs(\Codeception\Util\HttpCode::OK);
* ```
*
* @param $code
* Conditional Assertion: Test won't be stopped on fail
* @see \Codeception\Lib\InnerBrowser::seeResponseCodeIs()
*/
......@@ -2521,9 +2528,15 @@ trait FunctionalTesterActions
*
* Checks that response code is equal to value provided.
*
* @param $code
* ```php
* <?php
* $I->seeResponseCodeIs(200);
*
* @return mixed
* // recommended \Codeception\Util\HttpCode
* $I->seeResponseCodeIs(\Codeception\Util\HttpCode::OK);
* ```
*
* @param $code
* @see \Codeception\Lib\InnerBrowser::seeResponseCodeIs()
*/
public function seeResponseCodeIs($code) {
......@@ -2531,6 +2544,45 @@ trait FunctionalTesterActions
}
/**
* [!] Method is generated. Documentation taken from corresponding module.
*
* Checks that response code is equal to value provided.
*
* ```php
* <?php
* $I->dontSeeResponseCodeIs(200);
*
* // recommended \Codeception\Util\HttpCode
* $I->dontSeeResponseCodeIs(\Codeception\Util\HttpCode::OK);
* ```
* @param $code
* Conditional Assertion: Test won't be stopped on fail
* @see \Codeception\Lib\InnerBrowser::dontSeeResponseCodeIs()
*/
public function cantSeeResponseCodeIs($code) {
return $this->getScenario()->runStep(new \Codeception\Step\ConditionalAssertion('dontSeeResponseCodeIs', func_get_args()));
}
/**
* [!] Method is generated. Documentation taken from corresponding module.
*
* Checks that response code is equal to value provided.
*
* ```php
* <?php
* $I->dontSeeResponseCodeIs(200);
*
* // recommended \Codeception\Util\HttpCode
* $I->dontSeeResponseCodeIs(\Codeception\Util\HttpCode::OK);
* ```
* @param $code
* @see \Codeception\Lib\InnerBrowser::dontSeeResponseCodeIs()
*/
public function dontSeeResponseCodeIs($code) {
return $this->getScenario()->runStep(new \Codeception\Step\Assertion('dontSeeResponseCodeIs', func_get_args()));
}
/**
* [!] Method is generated. Documentation taken from corresponding module.
*
......@@ -2629,7 +2681,7 @@ trait FunctionalTesterActions
* [!] Method is generated. Documentation taken from corresponding module.
*
* Moves back in history.
*
*
* @param int $numberOfSteps (default value 1)
* @see \Codeception\Lib\InnerBrowser::moveBack()
*/
......
<?php //[STAMP] 9d226cb1973c9976b2a8dca3a7dfb7bb
<?php //[STAMP] efa60a632309a7a8ed739cd59858eef3
namespace _generated;
// This class was automatically generated by build task
......
......@@ -2,14 +2,6 @@
class ApplicationTest extends \PHPUnit_Framework_TestCase
{
protected function setUp()
{
}
protected function tearDown()
{
}
// tests
public function testApp()
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment