diff options
author | Igor Wiedler <igor@wiedler.ch> | 2012-06-27 14:47:13 +0200 |
---|---|---|
committer | Igor Wiedler <igor@wiedler.ch> | 2012-06-27 14:47:13 +0200 |
commit | 1b3cb68c2fdc5224367ddc3a9414c323c7d5bb7f (patch) | |
tree | 62898f931c8b82a198a4c0dc7bf4237c7b4e9077 /tests/functional/lang_test.php | |
parent | f273ab16ae68d15832832e2b2c98a3b99c966c97 (diff) | |
parent | 85ea062a0536edc46ea1a8893201777f8137e41e (diff) | |
download | forums-1b3cb68c2fdc5224367ddc3a9414c323c7d5bb7f.tar forums-1b3cb68c2fdc5224367ddc3a9414c323c7d5bb7f.tar.gz forums-1b3cb68c2fdc5224367ddc3a9414c323c7d5bb7f.tar.bz2 forums-1b3cb68c2fdc5224367ddc3a9414c323c7d5bb7f.tar.xz forums-1b3cb68c2fdc5224367ddc3a9414c323c7d5bb7f.zip |
Merge remote-tracking branch 'upstream/develop' into feature/avatars
* upstream/develop: (255 commits)
[ticket/10935] Limit number of PM rules per user to 5000
[ticket/10801] Fixed quickmod tools.
[ticket/9551] uncomment line and change length to 255
[ticket/10925] Clarify installation requirements for SQLite
[ticket/10938] Serve subforum listing on forumlist from template loop
[ticket/10640] Change subject length in mcp in subsilver
[ticket/10640] Change subject length in MCP
[ticket/10640] Do not change default value of truncate_string()
[ticket/10640] Change maximum subject length
[ticket/10936] remove PCRE and mbstring support check
[ticket/10936] fix language key
[ticket/10829] Delete T_STYLESHEET_NAME - no longer used.
[ticket/10829] $style_name -> $style_path in style class.
[ticket/10743] Renaming user->theme
[ticket/10743] Changing obtain_cfg_items
[ticket/10882] Fix test name - oops.
[ticket/10931] Apply strtolower() correctly, i.e. not on false.
[ticket/10931] Also test get_bytes() and get_string() with false.
[ticket/10931] Make to_numeric function globally available.
[ticket/10932] Use included composer.phar in build process
...
Conflicts:
phpBB/includes/mcp/mcp_warn.php
phpBB/install/database_update.php
phpBB/styles/prosilver/template/ucp_avatar_options.html
Diffstat (limited to 'tests/functional/lang_test.php')
-rw-r--r-- | tests/functional/lang_test.php | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/tests/functional/lang_test.php b/tests/functional/lang_test.php new file mode 100644 index 0000000000..053806a431 --- /dev/null +++ b/tests/functional/lang_test.php @@ -0,0 +1,45 @@ +<?php +/** +* +* @package testing +* @copyright (c) 2012 phpBB Group +* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License v2 +* +*/ + +/** +* @group functional +*/ +class phpbb_functional_lang_test extends phpbb_functional_test_case +{ + public function test_lang() + { + // Test a language string present in the common language file + $this->assertEquals('Board index', $this->lang('FORUM_INDEX')); + } + + /** + * @expectedException RuntimeException + */ + public function test_lang_missing() + { + $this->assertEquals('Your account has now been activated. Thank you for registering.', $this->lang('ACCOUNT_ACTIVE')); + } + + public function test_add_lang() + { + $this->add_lang('ucp'); + + // Test a language string present only in the UCP language file + $this->assertEquals('Your account has now been activated. Thank you for registering.', $this->lang('ACCOUNT_ACTIVE')); + } + + public function test_add_langs() + { + $this->add_lang(array('groups', 'memberlist')); + + // Test a language string from each UCP and memberlist + $this->assertEquals('The selected group is already your default group.', $this->lang('ALREADY_DEFAULT_GROUP')); + $this->assertEquals('Profile', $this->lang('ABOUT_USER')); + } +} |