mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 03:18:26 +00:00
Renaming method to match other core classes with similar features.
This commit is contained in:
parent
9b8456ce6f
commit
da632fe191
2 changed files with 4 additions and 4 deletions
|
@ -264,14 +264,14 @@ class Configure {
|
|||
*
|
||||
* To add a new reader to Configure:
|
||||
*
|
||||
* `Configure::reader('ini', new IniReader());`
|
||||
* `Configure::config('ini', new IniReader());`
|
||||
*
|
||||
* @param string $alias The name of the reader being configured. This alias is used later to
|
||||
* read values from a specific reader.
|
||||
* @param ConfigReaderInterface $reader The reader to append.
|
||||
* @return void
|
||||
*/
|
||||
public static function reader($alias, ConfigReaderInterface $reader) {
|
||||
public static function config($alias, ConfigReaderInterface $reader) {
|
||||
self::$_readers[$alias] = $reader;
|
||||
}
|
||||
|
||||
|
|
|
@ -265,7 +265,7 @@ class ConfigureTest extends CakeTestCase {
|
|||
*/
|
||||
function testReaderSetup() {
|
||||
$reader = new PhpReader();
|
||||
Configure::reader('test', $reader);
|
||||
Configure::config('test', $reader);
|
||||
$configured = Configure::configured();
|
||||
|
||||
$this->assertTrue(in_array('test', $configured));
|
||||
|
@ -279,7 +279,7 @@ class ConfigureTest extends CakeTestCase {
|
|||
*/
|
||||
function testReaderExceptionOnIncorrectClass() {
|
||||
$reader = new StdClass();
|
||||
Configure::reader('test', $reader);
|
||||
Configure::config('test', $reader);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue