CustomAssertions::assertHasTable
Usage
CustomAssertions::assertHasTable(string $table_alias)Description
Check for submit button final public function assertHasSubmit(string $value, string $label) { $this->checkHasSubmit($value, $label, true); } final public function assertNotHasSubmit(string $value, string $label) { $this->checkHasSubmit($value, $label, false); } private function checkHasSubmit(string $value, string $label, $has = true) { // Set variables $html = $this->res_body; $chk = ""; // Assert $ok = strpos($html, $chk) === false ? false : true; if ($ok !== $has) { $word = $has === true ? ' NOT ' : ''; $this->asserttrue(false, "The page does $word contain a submit button with the value: $value, and label: $label"); } else { $this->asserttrue(true); } } Check has data tableParameters
Parameter | Required | Type | Description |
---|---|---|---|
$table_alias | Yes | string |