mirror of
https://github.com/Pathduck/gallery3.git
synced 2026-06-05 19:29:06 -04:00
Consolidate all the random code into a random helper that offers:
random::hash() random::string() random::percent() random::int() So that we don't have lots of different ways to get random values all over the code. Follow-on to #1527.
This commit is contained in:
@@ -31,7 +31,7 @@ class Albums_Controller_Test extends Gallery_Unit_Test_Case {
|
||||
$album = test::random_album();
|
||||
|
||||
// Randomize to avoid conflicts.
|
||||
$new_name = "new_name_" . mt_rand();
|
||||
$new_name = "new_name_" . random::string(6);
|
||||
|
||||
$_POST["name"] = $new_name;
|
||||
$_POST["title"] = "new title";
|
||||
|
||||
Reference in New Issue
Block a user