@@ -17,8 +17,8 @@ Writing Functional Tests
1717========================
1818
1919Your test case will have to inherit from the ``phpbb_functional_test_case ``
20- class. You will be able to make requests to a fresh phpBB installation. Also
21- be sure, to put the file into the ``tests/functional/ `` folder and to add the
20+ class. You will be able to make requests to a fresh phpBB installation. Also,
21+ be sure to put the file into the ``tests/functional/ `` folder and to add the
2222``@group functional `` doc block above the class, so the tests are correctly
2323executed.
2424
@@ -43,10 +43,10 @@ executed.
4343 }
4444
4545
46- There is a bootstrap function where you can put code that is run before the
47- test. Here you can set up some initial state required for your test. Then you
48- can define your tests, just as you would normally, by prefixing methods with
49- ``test_ ``. In this case we will be testing the index.
46+ There is a `` bootstrap() `` method where you can put code that is run before the
47+ test. Here you can set up some objects after the installation that are required
48+ for your test. Then you can define your tests, just as you would normally, by
49+ prefixing methods with ``test_ ``. In this case we will be testing the index.
5050
5151Goutte and Assertions
5252---------------------
@@ -92,9 +92,10 @@ use the ``login()`` method inherited from the ``phpbb_functional_test_case``
9292class. This method will assign the user's SID to the inherited class property
9393``$this->sid ``. You will need to append this to the URLs that the logged-in
9494user will be navigating to in order to hold the session. For usage examples,
95- view the logout test in ``tests/functional/auth_test.php ``.
95+ view the logout test in
96+ `tests/functional/auth_test.php <https://github.com/phpbb/phpbb/blob/3.1.x/tests/functional/auth_test.php >`_.
9697
97- Localization
98+ Localisation
9899------------
99100
100101In tests, as in phpBB itself, do not use hard-coded language unless absolutely
@@ -120,4 +121,5 @@ framework.
120121 $this->assertEquals('Logout [ user ]', $this->lang('LOGOUT_USER', 'user'));
121122 }
122123
123- For more usage examples, please view ``tests/functional/lang_test.php ``.
124+ For more usage examples, please view
125+ `tests/functional/lang_test.php <https://github.com/phpbb/phpbb/blob/3.1.x/tests/functional/lang_test.php >`_.
0 commit comments