LoggedOutCest.php 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. <?php
  2. declare(strict_types = 1);
  3. class LoggedOutCest
  4. {
  5. private function run(AcceptanceTester $I, string $page, string $see): void
  6. {
  7. $I->amOnPage($page);
  8. $I->see($see);
  9. }
  10. public function root(AcceptanceTester $I)
  11. {
  12. $this->run($I, '/', 'Feed');
  13. }
  14. public function loginPage(AcceptanceTester $I)
  15. {
  16. $this->run($I, '/main/login', 'Login');
  17. }
  18. public function registerPage(AcceptanceTester $I)
  19. {
  20. $this->run($I, '/main/register', 'Register');
  21. }
  22. public function feed(AcceptanceTester $I)
  23. {
  24. $this->run($I, '/feed/public', 'Feed');
  25. }
  26. public function faq(AcceptanceTester $I)
  27. {
  28. $this->run($I, '/doc/faq', 'What is this site?');
  29. }
  30. public function tos(AcceptanceTester $I)
  31. {
  32. $this->run($I, '/doc/tos', 'TOS');
  33. }
  34. public function privacy(AcceptanceTester $I)
  35. {
  36. $this->run($I, '/doc/privacy', 'Privacy');
  37. }
  38. public function source(AcceptanceTester $I)
  39. {
  40. $this->run($I, '/doc/source', 'Source');
  41. }
  42. public function version(AcceptanceTester $I)
  43. {
  44. $this->run($I, '/doc/version', 'GNU social 3');
  45. }
  46. }