1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-05-29 10:39:19 +02:00

456 Commits

Author SHA1 Message Date
rxu
6585d938d2 [ticket/217] Adjust patch, add tests
PHPBB3-217
2011-06-06 00:53:53 +08:00
Nils Adermann
b55bfb459e Merge branch 'develop-olympus' into develop
* develop-olympus:
  [ticket/10042] GD CAPTCHA: Call phpbb_mt_rand() where required.
  [ticket/10042] GD CAPTCHA: Round offset to the next pixel.
  [ticket/10042] Add mt_rand() wrapper which allows swapping $min and $max.
2011-06-05 03:22:40 +02:00
Nils Adermann
893d0ae96f Merge branch 'ticket/bantu/10042' into develop-olympus
* ticket/bantu/10042:
  [ticket/10042] GD CAPTCHA: Call phpbb_mt_rand() where required.
  [ticket/10042] GD CAPTCHA: Round offset to the next pixel.
  [ticket/10042] Add mt_rand() wrapper which allows swapping $min and $max.
2011-06-05 03:22:09 +02:00
Nils Adermann
a2b6605ce8 [ticket/10005] Add description to test cases
PHPBB3-10005
2011-06-03 03:12:13 +02:00
Andreas Fischer
672c333ace Merge branch 'develop-olympus' into develop
* develop-olympus:
  [ticket/9685] Test for databases that are able to nest transactions
  [ticket/9685] Consistently name the new sql_buffer_nested_transactions function
2011-06-02 23:32:12 +02:00
Nils Adermann
7b10f859de [ticket/10005] Add validation of dropdown custom profile field values
PHPBB3-10005
2011-06-02 08:49:59 +02:00
Nils Adermann
f0287f7e57 [ticket/9685] Test for databases that are able to nest transactions
If a database is unable to nest transactions the dbal should implement
sql_buffer_nested_transactions to signal that buffering of the outer
results and closing of the outer transaction is required to open the
inner transaction.

PHPBB3-9685
2011-06-02 06:09:21 +02:00
Oleg Pudeyev
1d26398faa [feature/template-engine] Fixed copyright year.
PHPBB3-9726
2011-05-19 22:55:08 -04:00
Oleg Pudeyev
6ae5a64f6c [feature/template-engine] Fixed absolute path PHP includes, added test.
PHPBB3-9726
2011-05-19 12:18:16 -04:00
Oleg Pudeyev
efda4da19f [feature/template-engine] Moved includephp test to its own file.
PHPBB3-9726
2011-05-18 10:57:04 -04:00
Oleg Pudeyev
f24d858cff [feature/template-engine] Added tests for template inheritance.
PHPBB3-9726
2011-05-18 10:51:33 -04:00
Oleg Pudeyev
20b4df2853 [feature/template-engine] Delete useless template require.
It is now handled by autoloading.

PHPBB3-9726
2011-05-18 10:36:17 -04:00
Oleg Pudeyev
be8fc0864c [feature/template-engine] Added a test for inclusion of php files from subdir.
PHPBB3-9726
2011-05-14 15:30:20 -04:00
Oleg Pudeyev
94560d7086 [feature/template-engine] Make INCLUDEPHP relative to board root.
PHPBB3-9726
2011-05-12 20:13:32 -04:00
Oleg Pudeyev
d2ac05aa74 [feature/template-engine] Replaced globals with dependency injection.
PHPBB3-9726
2011-05-12 20:13:31 -04:00
Oleg Pudeyev
581374c9c3 [feature/template-engine] Deleted useless catch.
In tests there is no need to catch unexpected exceptions.

PHPBB3-9726
2011-05-12 20:13:31 -04:00
Oleg Pudeyev
ac9a910c64 [feature/template-engine] Delete obsolete comments pertaining to notices.
PHPBB3-9726
2011-05-12 20:13:31 -04:00
Oleg Pudeyev
0462ab3a4a [feature/template-engine] Add back IN_PHPBB preamble.
PHPBB3-9726
2011-05-12 20:13:30 -04:00
Oleg Pudeyev
87832d06cc [feature/template-engine] Delete template class, use phpbb_template instead.
PHPBB3-9726
2011-05-04 00:08:20 -04:00
Oleg Pudeyev
2aec6bb07c [feature/template-engine] Only copy files to cache if they exist.
When testing eval code path, compiled templates may not be written
to the file system, and unconditionally trying to copy them
breaks tests.

PHPBB3-9726
2011-05-01 03:12:23 -04:00
Oleg Pudeyev
b884573c1d [feature/template-engine] Relax missing file exception check.
As long as the exception message has the correct description and
file name we should not care which function raised the exception.

PHPBB3-9726
2011-05-01 03:11:13 -04:00
Igor Wiedler
427a5122d5 [feature/template-engine] Fix negative variable expressions
compile_tag_if had the flawed approach of adding an isset statement for
all variables to the beginning of the if. This fails for negative
expressions, and checking those takes a considerable effort.

The easier solution is to make the variable expression itself
conditional, defaulting to null if it is not set.

Thanks to naderman for the solution.

PHPBB3-9726
2011-04-25 23:19:36 -04:00
Oleg Pudeyev
f0b97cfdcf [feature/template-engine] Added a test for reuse of loop identifiers.
This currently does not pass, thus it is commented out.

The reuse appears implausible in the same file, however it may be
also done across template files where it is much harder to detect.

PHPBB3-9726
2011-04-25 23:19:32 -04:00
Oleg Pudeyev
f97411b911 [feature/template-engine] Corrected miscompilation of loop size constructs.
PHPBB3-9726
2011-04-25 23:19:25 -04:00
Oleg Pudeyev
5afc0b9b90 [feature/template-engine] Corrected an off-by-one error in nested namespaces.
This error resulted in a dot from the namespace being placed into
variable reference in compiled template code, thus creating bogus
compiled template code.

PHPBB3-9726
2011-04-24 23:13:13 -04:00
Oleg Pudeyev
e10d62badc [feature/template-engine] Added a test for multilevel references in loops.
This currently fails.

This test is a reduced version of permission_mask template in acp, which
is not correctly compiled by the current template engine code.

PHPBB3-9726
2011-04-24 21:56:26 -04:00
Oleg Pudeyev
5c3ebb3465 [feature/template-engine] Deleted silencing of notices.
The code is now supposed to be notice-free, therefore there is no need
to have the notices silenced.

PHPBB3-9726
2011-04-24 21:22:43 -04:00
Oleg Pudeyev
a2c75f6053 [feature/template-engine] Deleted $template from phpbb_template_compile class.
phpbb_template_compile is now much simpler. It takes complete file paths
as inputs, either source template path or source template path and output
compiled template path. The number of methods also went down to two -
compile template and returned compiled text or compile and write to file.

phpbb_compile class is responsible for determining source and compiled
paths. It already had all the data necessary for this, now the code is
in the same place as the data it uses.

PHPBB3-9726
2011-04-24 21:18:18 -04:00
Oleg Pudeyev
f29f32e0d6 [feature/template-engine] Allow leading underscores in variable names.
Subsilver uses ._file in overall_header.

PHPBB3-9726
2011-04-24 01:08:48 -04:00
Oleg Pudeyev
203187a841 [feature/template-engine] Fix recompilation logic.
Do not change $recompile from true to false - any recompilation
condition alone is sufficient to force recompilation.

Also uncomment the nonexistent file test which passes with this fix.

PHPBB3-9726
2011-04-24 01:08:48 -04:00
Oleg Pudeyev
4dfe4c7f13 [feature/template-engine] Adjust path in includephp template.
Now that tests are run from top level the '..' is wrong.

PHPBB3-9726
2011-04-24 01:08:30 -04:00
Marek A. Ruszczynski
4b646c6c80 [feature/template-engine] Update tests.
PHPBB3-9726
2011-04-23 22:48:50 -04:00
Oleg Pudeyev
5e7c945de9 [ticket/10143] Added tests for storing a previously deleted value in db cache.
PHPBB3-10143
2011-04-21 23:00:25 -04:00
Erik Frèrejean
503b87da48 [ticket/10006] More testing
Change the DB test to test agains new cache/config mock objects

PHPBB3-10006
2011-04-18 12:28:47 +02:00
Erik Frèrejean
7b1638c37f [ticket/10006] Tweak the tests a bit
PHPBB3-10006
2011-04-18 12:28:47 +02:00
Erik Frèrejean
2f67ade05a [ticket/10006] Add phpbb_config::delete
Add the missing `phpbb_config::delete` method to the config class

PHPBB3-10006
2011-04-18 12:28:47 +02:00
Andreas Fischer
ebc338b9f3 Merge branch 'develop-olympus' into develop
* develop-olympus:
  [ticket/9751] Add shortcut logic for pass_complex == PASS_TYPE_ANY.
  [ticket/9751] Compare $password with empty string instead of casting it to bool
  [ticket/9751] Use a switch/case block without break for password complexity.
  [ticket/9751] Password requirement "Must contain letters and numbers" fails
2011-04-01 15:11:55 +02:00
rxu
a835189823 [ticket/9751] Password requirement "Must contain letters and numbers" fails
PHPBB3-9751
2011-04-01 15:10:29 +02:00
Oleg Pudeyev
1312e5b965 Merge branch 'develop-olympus' into develop
* develop-olympus:
  [ticket/10082] session_id is CHAR(32) not VARCHAR(32), so give them a CHAR(32).
2011-03-23 20:32:03 -04:00
Oleg Pudeyev
df6ce22fa3 Merge branch 'ticket/bantu/10082' into develop-olympus
* ticket/bantu/10082:
  [ticket/10082] session_id is CHAR(32) not VARCHAR(32), so give them a CHAR(32).
2011-03-23 20:30:23 -04:00
Oleg Pudeyev
352ed5acf8 Merge branch 'develop-olympus' into develop
* develop-olympus:
  [ticket/10101] Add test case for native phpass hashes
  [ticket/10101] Add support for native phpass hashes
2011-03-22 21:25:14 -04:00
Igor Wiedler
4c3cc152c8 [ticket/10101] Add test case for native phpass hashes
PHPBB3-10101
2011-03-20 22:52:31 +01:00
Andreas Fischer
d36f78b9f1 [ticket/10082] session_id is CHAR(32) not VARCHAR(32), so give them a CHAR(32).
This fixes session unit tests on PostgreSQL in particular.

PHPBB3-10082
2011-03-19 23:20:41 +01:00
Igor Wiedler
d319fe1883 Merge branch 'develop-olympus' into develop
* develop-olympus:
  [ticket/10088] Also ignore DBMS versions other than MySQLi in cache mock.
2011-03-12 18:23:47 +01:00
Andreas Fischer
7a39bdef89 [ticket/10088] Also ignore DBMS versions other than MySQLi in cache mock.
PHPBB3-10088
2011-03-12 15:26:09 +01:00
Nils Adermann
ffb697f7d0 Merge branch 'ticket/naderman/10080' into develop
* ticket/naderman/10080:
  [ticket/10080] Allow resetting the request instance used by request_var.
2011-03-07 19:19:49 +01:00
Nils Adermann
a0930e78c6 Merge branch 'develop-olympus' into develop
* develop-olympus:
  [ticket/10081] remove $phpEx.
  [ticket/10081] Cleanup Template Tests.
2011-03-07 19:10:19 +01:00
Nils Adermann
458b8841eb [ticket/10080] Allow resetting the request instance used by request_var.
PHPBB3-10080
2011-03-07 18:54:52 +01:00
Marek A. Ruszczynski
b835f364f5 [ticket/10081] remove $phpEx.
PHPBB3-10081
2011-03-07 18:50:18 +01:00
Marek A. Ruszczynski
7147382e9e [ticket/10081] Cleanup Template Tests.
There are no incomplete template tests anymore.

PHPBB3-10081
2011-03-07 18:26:46 +01:00