Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

coding standards according to new sniffer rules

  • Loading branch information...
commit 1339a9dfe16b2508c706c6b50d345c73b9e66601 1 parent 19b4021
@dereuromark dereuromark authored
Showing with 75 additions and 75 deletions.
  1. +4 −4 lib/Cake/Test/Case/Cache/Engine/FileEngineTest.php
  2. +1 −1  lib/Cake/Test/Case/Core/ObjectTest.php
  3. +1 −1  lib/Cake/Test/Case/Error/ExceptionRendererTest.php
  4. +2 −2 lib/Cake/Test/Case/Model/Datasource/Database/MysqlTest.php
  5. +6 −6 lib/Cake/Test/Case/Model/ModelIntegrationTest.php
  6. +1 −1  lib/Cake/Test/Case/Model/ModelWriteTest.php
  7. +3 −3 lib/Cake/Test/Case/Network/Email/CakeEmailTest.php
  8. +6 −6 lib/Cake/Test/Case/Network/Http/HttpSocketTest.php
  9. +1 −1  lib/Cake/Test/Case/Routing/Route/CakeRouteTest.php
  10. +1 −1  lib/Cake/Test/Case/Routing/RouterTest.php
  11. +14 −14 lib/Cake/Test/Case/Utility/SetTest.php
  12. +2 −2 lib/Cake/Test/Case/Utility/StringTest.php
  13. +4 −4 lib/Cake/Test/Case/View/Helper/FormHelperTest.php
  14. +1 −1  lib/Cake/Test/Case/View/Helper/JsHelperTest.php
  15. +1 −1  lib/Cake/Test/Case/View/Helper/MootoolsEngineHelperTest.php
  16. +1 −1  lib/Cake/Test/Case/View/Helper/PaginatorHelperTest.php
  17. +2 −2 lib/Cake/Test/Fixture/AcoTwoFixture.php
  18. +2 −2 lib/Cake/Test/Fixture/AroTwoFixture.php
  19. +5 −5 lib/Cake/Test/Fixture/FlagTreeFixture.php
  20. +4 −4 lib/Cake/Test/Fixture/NumberTreeFixture.php
  21. +4 −4 lib/Cake/Test/Fixture/NumberTreeTwoFixture.php
  22. +4 −4 lib/Cake/Test/Fixture/UnconventionalTreeFixture.php
  23. +3 −3 lib/Cake/Utility/CakeNumber.php
  24. +1 −1  lib/Cake/Utility/String.php
  25. +1 −1  lib/Cake/View/Helper.php
View
8 lib/Cake/Test/Case/Cache/Engine/FileEngineTest.php
@@ -401,7 +401,7 @@ public function testMaskSetting() {
Cache::config('mask_test', array('engine' => 'File', 'path' => TMP . 'tests'));
$data = 'This is some test content';
$write = Cache::write('masking_test', $data, 'mask_test');
- $result = substr(sprintf('%o',fileperms(TMP . 'tests' . DS . 'cake_masking_test')), -4);
+ $result = substr(sprintf('%o', fileperms(TMP . 'tests' . DS . 'cake_masking_test')), -4);
$expected = '0664';
$this->assertEquals($expected, $result);
Cache::delete('masking_test', 'mask_test');
@@ -409,7 +409,7 @@ public function testMaskSetting() {
Cache::config('mask_test', array('engine' => 'File', 'mask' => 0666, 'path' => TMP . 'tests'));
$write = Cache::write('masking_test', $data, 'mask_test');
- $result = substr(sprintf('%o',fileperms(TMP . 'tests' . DS . 'cake_masking_test')), -4);
+ $result = substr(sprintf('%o', fileperms(TMP . 'tests' . DS . 'cake_masking_test')), -4);
$expected = '0666';
$this->assertEquals($expected, $result);
Cache::delete('masking_test', 'mask_test');
@@ -417,7 +417,7 @@ public function testMaskSetting() {
Cache::config('mask_test', array('engine' => 'File', 'mask' => 0644, 'path' => TMP . 'tests'));
$write = Cache::write('masking_test', $data, 'mask_test');
- $result = substr(sprintf('%o',fileperms(TMP . 'tests' . DS . 'cake_masking_test')), -4);
+ $result = substr(sprintf('%o', fileperms(TMP . 'tests' . DS . 'cake_masking_test')), -4);
$expected = '0644';
$this->assertEquals($expected, $result);
Cache::delete('masking_test', 'mask_test');
@@ -425,7 +425,7 @@ public function testMaskSetting() {
Cache::config('mask_test', array('engine' => 'File', 'mask' => 0640, 'path' => TMP . 'tests'));
$write = Cache::write('masking_test', $data, 'mask_test');
- $result = substr(sprintf('%o',fileperms(TMP . 'tests' . DS . 'cake_masking_test')), -4);
+ $result = substr(sprintf('%o', fileperms(TMP . 'tests' . DS . 'cake_masking_test')), -4);
$expected = '0640';
$this->assertEquals($expected, $result);
Cache::delete('masking_test', 'mask_test');
View
2  lib/Cake/Test/Case/Core/ObjectTest.php
@@ -598,7 +598,7 @@ public function testRequestActionParamParseAndPass() {
$this->assertEquals(null, $result['plugin']);
$result = $this->object->requestAction('/request_action/params_pass/sort:desc/limit:5');
- $expected = array('sort' => 'desc', 'limit' => 5,);
+ $expected = array('sort' => 'desc', 'limit' => 5);
$this->assertEquals($expected, $result['named']);
$result = $this->object->requestAction(
View
2  lib/Cake/Test/Case/Error/ExceptionRendererTest.php
@@ -528,7 +528,7 @@ public static function testProvider() {
404
),
array(
- new PrivateActionException(array('controller' => 'PostsController' , 'action' => '_secretSauce')),
+ new PrivateActionException(array('controller' => 'PostsController', 'action' => '_secretSauce')),
array(
'/<h2>Private Method in PostsController<\/h2>/',
'/<em>PostsController::<\/em><em>_secretSauce\(\)<\/em>/'
View
4 lib/Cake/Test/Case/Model/Datasource/Database/MysqlTest.php
@@ -2407,7 +2407,7 @@ public function testArrayConditionsParsing() {
$this->assertEquals($expected, $result);
$result = $this->Dbo->conditions(array(
- 'NOT' => array('Course.id' => null, 'Course.vet' => 'N', 'level_of_education_id' => array(912,999)),
+ 'NOT' => array('Course.id' => null, 'Course.vet' => 'N', 'level_of_education_id' => array(912, 999)),
'Enrollment.yearcompleted >' => '0')
);
$this->assertRegExp('/^\s*WHERE\s+\(NOT\s+\(`Course`\.`id` IS NULL\)\s+AND NOT\s+\(`Course`\.`vet`\s+=\s+\'N\'\)\s+AND NOT\s+\(`level_of_education_id` IN \(912, 999\)\)\)\s+AND\s+`Enrollment`\.`yearcompleted`\s+>\s+\'0\'\s*$/', $result);
@@ -3267,7 +3267,7 @@ public function testVirtualFieldsInConditions() {
$expected = '(1 + 1) = 2';
$this->assertEquals($expected, $result);
- $conditions = array('this_moment BETWEEN ? AND ?' => array(1,2));
+ $conditions = array('this_moment BETWEEN ? AND ?' => array(1, 2));
$expected = 'NOW() BETWEEN 1 AND 2';
$result = $this->Dbo->conditions($conditions, true, false, $Article);
$this->assertEquals($expected, $result);
View
12 lib/Cake/Test/Case/Model/ModelIntegrationTest.php
@@ -836,16 +836,16 @@ public function testHABTMKeepExistingWithThreeDbs() {
$this->assertEquals('test_database_three', $Player->ArmorsPlayer->useDbConfig);
$players = $Player->find('all');
- $this->assertEquals(4 , count($players));
+ $this->assertEquals(4, count($players));
$playersGuilds = Hash::extract($players, '{n}.Guild.{n}.GuildsPlayer');
- $this->assertEquals(3 , count($playersGuilds));
+ $this->assertEquals(3, count($playersGuilds));
$playersArmors = Hash::extract($players, '{n}.Armor.{n}.ArmorsPlayer');
- $this->assertEquals(3 , count($playersArmors));
+ $this->assertEquals(3, count($playersArmors));
unset($players);
$larry = $Player->findByName('larry');
$larrysArmor = Hash::extract($larry, 'Armor.{n}.ArmorsPlayer');
- $this->assertEquals(1 , count($larrysArmor));
+ $this->assertEquals(1, count($larrysArmor));
$larry['Guild']['Guild'] = array(1, 3); // larry joins another guild
$larry['Armor']['Armor'] = array(2, 3); // purchases chainmail
@@ -854,9 +854,9 @@ public function testHABTMKeepExistingWithThreeDbs() {
$larry = $Player->findByName('larry');
$larrysGuild = Hash::extract($larry, 'Guild.{n}.GuildsPlayer');
- $this->assertEquals(2 , count($larrysGuild));
+ $this->assertEquals(2, count($larrysGuild));
$larrysArmor = Hash::extract($larry, 'Armor.{n}.ArmorsPlayer');
- $this->assertEquals(2 , count($larrysArmor));
+ $this->assertEquals(2, count($larrysArmor));
$Player->ArmorsPlayer->id = 3;
$Player->ArmorsPlayer->saveField('broken', true); // larry's cloak broke
View
2  lib/Cake/Test/Case/Model/ModelWriteTest.php
@@ -4941,7 +4941,7 @@ public function testSaveAssociatedAtomicFalseValidateFirstWithErrors() {
$expected = array(
'Comment' => array(
array(
- 'comment' => array( 'This field cannot be left blank' )
+ 'comment' => array('This field cannot be left blank')
)
)
);
View
6 lib/Cake/Test/Case/Network/Email/CakeEmailTest.php
@@ -1669,7 +1669,7 @@ public function testBodyEncoding() {
$email->to('someone@example.com')->from('someone@example.com');
$result = $email->send('ってテーブルを作ってやってたらう');
$this->assertContains('Content-Type: text/plain; charset=ISO-2022-JP', $result['headers']);
- $this->assertContains(mb_convert_encoding('ってテーブルを作ってやってたらう','ISO-2022-JP'), $result['message']);
+ $this->assertContains(mb_convert_encoding('ってテーブルを作ってやってたらう', 'ISO-2022-JP'), $result['message']);
}
/**
@@ -1693,7 +1693,7 @@ public function testBodyEncodingIso2022Jp() {
$result = $email->send('①㈱');
$this->assertTextContains("Content-Type: text/plain; charset=ISO-2022-JP", $result['headers']);
$this->assertTextNotContains("Content-Type: text/plain; charset=ISO-2022-JP-MS", $result['headers']); // not charset=iso-2022-jp-ms
- $this->assertTextNotContains(mb_convert_encoding('①㈱','ISO-2022-JP-MS'), $result['message']);
+ $this->assertTextNotContains(mb_convert_encoding('①㈱', 'ISO-2022-JP-MS'), $result['message']);
}
/**
@@ -1717,7 +1717,7 @@ public function testBodyEncodingIso2022JpMs() {
$result = $email->send('①㈱');
$this->assertTextContains("Content-Type: text/plain; charset=ISO-2022-JP", $result['headers']);
$this->assertTextNotContains("Content-Type: text/plain; charset=iso-2022-jp-ms", $result['headers']); // not charset=iso-2022-jp-ms
- $this->assertContains(mb_convert_encoding('①㈱','ISO-2022-JP-MS'), $result['message']);
+ $this->assertContains(mb_convert_encoding('①㈱', 'ISO-2022-JP-MS'), $result['message']);
}
protected function _checkContentTransferEncoding($message, $charset) {
View
12 lib/Cake/Test/Case/Network/Http/HttpSocketTest.php
@@ -1520,8 +1520,8 @@ public function testParseQuery() {
'name' => 'jim',
'items' => array(
'personal' => array(
- 'book'
- , 'pen'
+ 'book',
+ 'pen'
),
'ball'
)
@@ -1608,10 +1608,10 @@ public function testTokenEscapeChars() {
$this->Socket->reset();
$expected = array(
- '\x22','\x28','\x29','\x3c','\x3e','\x40','\x2c','\x3b','\x3a','\x5c','\x2f','\x5b','\x5d','\x3f','\x3d','\x7b',
- '\x7d','\x20','\x00','\x01','\x02','\x03','\x04','\x05','\x06','\x07','\x08','\x09','\x0a','\x0b','\x0c','\x0d',
- '\x0e','\x0f','\x10','\x11','\x12','\x13','\x14','\x15','\x16','\x17','\x18','\x19','\x1a','\x1b','\x1c','\x1d',
- '\x1e','\x1f','\x7f'
+ '\x22', '\x28', '\x29', '\x3c', '\x3e', '\x40', '\x2c', '\x3b', '\x3a', '\x5c', '\x2f', '\x5b', '\x5d', '\x3f', '\x3d', '\x7b',
+ '\x7d', '\x20', '\x00', '\x01', '\x02', '\x03', '\x04', '\x05', '\x06', '\x07', '\x08', '\x09', '\x0a', '\x0b', '\x0c', '\x0d',
+ '\x0e', '\x0f', '\x10', '\x11', '\x12', '\x13', '\x14', '\x15', '\x16', '\x17', '\x18', '\x19', '\x1a', '\x1b', '\x1c', '\x1d',
+ '\x1e', '\x1f', '\x7f'
);
$r = $this->Socket->tokenEscapeChars();
$this->assertEquals($expected, $r);
View
2  lib/Cake/Test/Case/Routing/Route/CakeRouteTest.php
@@ -923,7 +923,7 @@ public function testParseTrailingUTF8() {
public function testUTF8PatternOnSection() {
$route = new CakeRoute(
'/:section',
- array('plugin' => 'blogs', 'controller' => 'posts' , 'action' => 'index' ),
+ array('plugin' => 'blogs', 'controller' => 'posts', 'action' => 'index'),
array(
'persist' => array('section'),
'section' => 'آموزش|weblog'
View
2  lib/Cake/Test/Case/Routing/RouterTest.php
@@ -944,7 +944,7 @@ public function testCanLeavePlugin() {
public function testUrlParsing() {
extract(Router::getNamedExpressions());
- Router::connect('/posts/:value/:somevalue/:othervalue/*', array('controller' => 'posts', 'action' => 'view'), array('value','somevalue', 'othervalue'));
+ Router::connect('/posts/:value/:somevalue/:othervalue/*', array('controller' => 'posts', 'action' => 'view'), array('value', 'somevalue', 'othervalue'));
$result = Router::parse('/posts/2007/08/01/title-of-post-here');
$expected = array('value' => '2007', 'somevalue' => '08', 'othervalue' => '01', 'controller' => 'posts', 'action' => 'view', 'plugin' => '', 'pass' => array('0' => 'title-of-post-here'), 'named' => array());
$this->assertEquals($expected, $result);
View
28 lib/Cake/Test/Case/Utility/SetTest.php
@@ -256,7 +256,7 @@ public function testSort() {
$a = array(
0 => array('Person' => array('name' => 'Jeff'), 'Friend' => array(array('name' => 'Nate'))),
- 1 => array('Person' => array('name' => 'Tracy'),'Friend' => array(array('name' => 'Lindsay'))),
+ 1 => array('Person' => array('name' => 'Tracy'), 'Friend' => array(array('name' => 'Lindsay'))),
2 => array('Person' => array('name' => 'Adam'), 'Friend' => array(array('name' => 'Bob')))
);
$b = array(
@@ -268,15 +268,15 @@ public function testSort() {
$this->assertEquals($a, $b);
$a = array(
- array(7,6,4),
- array(3,4,5),
- array(3,2,1),
+ array(7, 6, 4),
+ array(3, 4, 5),
+ array(3, 2, 1),
);
$b = array(
- array(3,2,1),
- array(3,4,5),
- array(7,6,4),
+ array(3, 2, 1),
+ array(3, 4, 5),
+ array(7, 6, 4),
);
$a = Set::sort($a, '{n}.{n}', 'asc');
@@ -884,7 +884,7 @@ public function testExtract() {
$r = Set::extract('/file/.[type=application/x-zip-compressed]', $f);
$this->assertEquals($expected, $r);
- $expected = array(array('name' => 'zipfile.zip', 'type' => 'application/zip','tmp_name' => '/tmp/php178.tmp', 'error' => 0, 'size' => '564647'));
+ $expected = array(array('name' => 'zipfile.zip', 'type' => 'application/zip', 'tmp_name' => '/tmp/php178.tmp', 'error' => 0, 'size' => '564647'));
$r = Set::extract('/file/.[type=application/zip]', $f);
$this->assertEquals($expected, $r);
@@ -922,8 +922,8 @@ public function testExtract() {
$this->assertEquals($expected, $r);
$expected = array(
- array('name' => 'zipfile.zip','type' => 'application/zip', 'tmp_name' => '/tmp/php178.tmp', 'error' => 0, 'size' => '564647'),
- array('name' => 'zipfile2.zip','type' => 'application/x zip compressed', 'tmp_name' => '/tmp/php179.tmp', 'error' => 0, 'size' => '354784')
+ array('name' => 'zipfile.zip', 'type' => 'application/zip', 'tmp_name' => '/tmp/php178.tmp', 'error' => 0, 'size' => '564647'),
+ array('name' => 'zipfile2.zip', 'type' => 'application/x zip compressed', 'tmp_name' => '/tmp/php179.tmp', 'error' => 0, 'size' => '354784')
);
$r = Set::extract('/file/.[tmp_name=/tmp\/php17/]', $f);
$this->assertEquals($expected, $r);
@@ -1110,7 +1110,7 @@ public function testExtractParentSelector() {
)
);
- $expected = array(7,2,1);
+ $expected = array(7, 2, 1);
$r = Set::extract('/CallType[name=Internal Voice]/../x/hour', $multiple);
$this->assertEquals($expected, $r);
@@ -1856,7 +1856,7 @@ public function testCombine() {
$a = array(
array('User' => array('id' => 2, 'group_id' => 1,
- 'Data' => array('user' => 'mariano.iglesias','name' => 'Mariano Iglesias'))),
+ 'Data' => array('user' => 'mariano.iglesias', 'name' => 'Mariano Iglesias'))),
array('User' => array('id' => 14, 'group_id' => 2,
'Data' => array('user' => 'phpnut', 'name' => 'Larry E. Masters'))),
array('User' => array('id' => 25, 'group_id' => 1,
@@ -2470,8 +2470,8 @@ public function testNestedMappedData() {
array(
'Post' => array('id' => '1', 'author_id' => '1', 'title' => 'First Post', 'body' => 'First Post Body', 'published' => 'Y', 'created' => '2007-03-18 10:39:23', 'updated' => '2007-03-18 10:41:31'),
'Author' => array('id' => '1', 'user' => 'mariano', 'password' => '5f4dcc3b5aa765d61d8327deb882cf99', 'created' => '2007-03-17 01:16:23', 'updated' => '2007-03-17 01:18:31', 'test' => 'working'),
- )
- , array(
+ ),
+ array(
'Post' => array('id' => '2', 'author_id' => '3', 'title' => 'Second Post', 'body' => 'Second Post Body', 'published' => 'Y', 'created' => '2007-03-18 10:41:23', 'updated' => '2007-03-18 10:43:31'),
'Author' => array('id' => '3', 'user' => 'larry', 'password' => '5f4dcc3b5aa765d61d8327deb882cf99', 'created' => '2007-03-17 01:20:23', 'updated' => '2007-03-17 01:22:31', 'test' => 'working'),
)
View
4 lib/Cake/Test/Case/Utility/StringTest.php
@@ -180,7 +180,7 @@ public function testInsert() {
$expected = "this is a long string with a few? params you know";
$this->assertEquals($expected, $result);
- $result = String::insert('update saved_urls set url = :url where id = :id', array('url' => 'http://www.testurl.com/param1:url/param2:id','id' => 1));
+ $result = String::insert('update saved_urls set url = :url where id = :id', array('url' => 'http://www.testurl.com/param1:url/param2:id', 'id' => 1));
$expected = "update saved_urls set url = http://www.testurl.com/param1:url/param2:id where id = 1";
$this->assertEquals($expected, $result);
@@ -334,7 +334,7 @@ public function testWrap() {
This is the song th
at never ends. This
is the song that n
-ever ends. This is
+ever ends. This is
the song that never
ends.
TEXT;
View
8 lib/Cake/Test/Case/View/Helper/FormHelperTest.php
@@ -1388,7 +1388,7 @@ public function testDisableSecurityUsingForm() {
$this->Form->input('Addresses.first_name', array('secure' => false));
$this->Form->input('Addresses.city', array('type' => 'textarea', 'secure' => false));
$this->Form->input('Addresses.zip', array(
- 'type' => 'select', 'options' => array(1,2), 'secure' => false
+ 'type' => 'select', 'options' => array(1, 2), 'secure' => false
));
$result = $this->Form->fields;
@@ -1719,7 +1719,7 @@ public function testFormValidationAssociatedSecondLevel() {
$result = $this->Form->create('ValidateUser', array('type' => 'post', 'action' => 'add'));
$encoding = strtolower(Configure::read('App.encoding'));
$expected = array(
- 'form' => array('method' => 'post', 'action' => '/validate_users/add', 'id','accept-charset' => $encoding),
+ 'form' => array('method' => 'post', 'action' => '/validate_users/add', 'id', 'accept-charset' => $encoding),
'div' => array('style' => 'display:none;'),
'input' => array('type' => 'hidden', 'name' => '_method', 'value' => 'POST'),
'/div'
@@ -2267,8 +2267,8 @@ public function testInputTime() {
$this->assertRegExp('#<option value="15"[^>]*>15</option>#', $result[1]);
$result = $this->Form->input('prueba', array(
- 'type' => 'time', 'timeFormat' => 24 , 'dateFormat' => 'DMY' , 'minYear' => 2008,
- 'maxYear' => date('Y') + 1 , 'interval' => 15
+ 'type' => 'time', 'timeFormat' => 24, 'dateFormat' => 'DMY', 'minYear' => 2008,
+ 'maxYear' => date('Y') + 1, 'interval' => 15
));
$result = explode(':', $result);
$this->assertNotRegExp('#<option value="12"[^>]*>12</option>#', $result[1]);
View
2  lib/Cake/Test/Case/View/Helper/JsHelperTest.php
@@ -873,7 +873,7 @@ public function testObject() {
$object = new JsEncodingObject();
$object->title = 'New thing';
- $object->indexes = array(5,6,7,8);
+ $object->indexes = array(5, 6, 7, 8);
$result = $this->JsEngine->object($object);
$this->assertEquals($expected, $result);
View
2  lib/Cake/Test/Case/View/Helper/MootoolsEngineHelperTest.php
@@ -266,7 +266,7 @@ public function testDrag() {
'start' => 'onStart',
'drag' => 'onDrag',
'stop' => 'onStop',
- 'snapGrid' => array(10,10),
+ 'snapGrid' => array(10, 10),
'wrapCallbacks' => false
));
$expected = '$("drag-me").makeDraggable({onComplete:onStop, onDrag:onDrag, onStart:onStart, snap:[10,10]});';
View
2  lib/Cake/Test/Case/View/Helper/PaginatorHelperTest.php
@@ -290,7 +290,7 @@ public function testSortLinksUsingDirectionOption() {
Router::setRequestInfo(array(
array('plugin' => null, 'controller' => 'accounts', 'action' => 'index', 'pass' => array(),
'url' => array('url' => 'accounts/', 'mod_rewrite' => 'true')),
- array('base' => '/', 'here' => '/accounts/', 'webroot' => '/',)
+ array('base' => '/', 'here' => '/accounts/', 'webroot' => '/')
));
$this->Paginator->options(array('url' => array('param')));
View
4 lib/Cake/Test/Fixture/AcoTwoFixture.php
@@ -47,13 +47,13 @@ class AcoTwoFixture extends CakeTestFixture {
*/
public $records = array(
array('parent_id' => null, 'model' => null, 'foreign_key' => null, 'alias' => 'ROOT', 'lft' => 1, 'rght' => 20),
- array('parent_id' => 1, 'model' => null, 'foreign_key' => null, 'alias' => 'tpsReports','lft' => 2, 'rght' => 9),
+ array('parent_id' => 1, 'model' => null, 'foreign_key' => null, 'alias' => 'tpsReports', 'lft' => 2, 'rght' => 9),
array('parent_id' => 2, 'model' => null, 'foreign_key' => null, 'alias' => 'view', 'lft' => 3, 'rght' => 6),
array('parent_id' => 3, 'model' => null, 'foreign_key' => null, 'alias' => 'current', 'lft' => 4, 'rght' => 5),
array('parent_id' => 2, 'model' => null, 'foreign_key' => null, 'alias' => 'update', 'lft' => 7, 'rght' => 8),
array('parent_id' => 1, 'model' => null, 'foreign_key' => null, 'alias' => 'printers', 'lft' => 10, 'rght' => 19),
array('parent_id' => 6, 'model' => null, 'foreign_key' => null, 'alias' => 'print', 'lft' => 11, 'rght' => 14),
- array('parent_id' => 7, 'model' => null, 'foreign_key' => null, 'alias' => 'lettersize','lft' => 12, 'rght' => 13),
+ array('parent_id' => 7, 'model' => null, 'foreign_key' => null, 'alias' => 'lettersize', 'lft' => 12, 'rght' => 13),
array('parent_id' => 6, 'model' => null, 'foreign_key' => null, 'alias' => 'refill', 'lft' => 15, 'rght' => 16),
array('parent_id' => 6, 'model' => null, 'foreign_key' => null, 'alias' => 'smash', 'lft' => 17, 'rght' => 18),
);
View
4 lib/Cake/Test/Fixture/AroTwoFixture.php
@@ -51,8 +51,8 @@ class AroTwoFixture extends CakeTestFixture {
array('parent_id' => 1, 'model' => 'Group', 'foreign_key' => '2', 'alias' => 'managers', 'lft' => '6', 'rght' => '9'),
array('parent_id' => 1, 'model' => 'Group', 'foreign_key' => '3', 'alias' => 'users', 'lft' => '10', 'rght' => '19'),
array('parent_id' => 2, 'model' => 'User', 'foreign_key' => '1', 'alias' => 'Bobs', 'lft' => '3', 'rght' => '4'),
- array('parent_id' => 3, 'model' => 'User', 'foreign_key' => '2', 'alias' => 'Lumbergh', 'lft' => '7' , 'rght' => '8'),
- array('parent_id' => 4, 'model' => 'User', 'foreign_key' => '3', 'alias' => 'Samir', 'lft' => '11' , 'rght' => '12'),
+ array('parent_id' => 3, 'model' => 'User', 'foreign_key' => '2', 'alias' => 'Lumbergh', 'lft' => '7', 'rght' => '8'),
+ array('parent_id' => 4, 'model' => 'User', 'foreign_key' => '3', 'alias' => 'Samir', 'lft' => '11', 'rght' => '12'),
array('parent_id' => 4, 'model' => 'User', 'foreign_key' => '4', 'alias' => 'Micheal', 'lft' => '13', 'rght' => '14'),
array('parent_id' => 4, 'model' => 'User', 'foreign_key' => '5', 'alias' => 'Peter', 'lft' => '15', 'rght' => '16'),
array('parent_id' => 4, 'model' => 'User', 'foreign_key' => '6', 'alias' => 'Milton', 'lft' => '17', 'rght' => '18'),
View
10 lib/Cake/Test/Fixture/FlagTreeFixture.php
@@ -35,11 +35,11 @@ class FlagTreeFixture extends CakeTestFixture {
* @var array
*/
public $fields = array(
- 'id' => array('type' => 'integer','key' => 'primary'),
- 'name' => array('type' => 'string','null' => false),
+ 'id' => array('type' => 'integer', 'key' => 'primary'),
+ 'name' => array('type' => 'string', 'null' => false),
'parent_id' => 'integer',
- 'lft' => array('type' => 'integer','null' => false),
- 'rght' => array('type' => 'integer','null' => false),
- 'flag' => array('type' => 'integer','null' => false, 'length' => 1, 'default' => 0)
+ 'lft' => array('type' => 'integer', 'null' => false),
+ 'rght' => array('type' => 'integer', 'null' => false),
+ 'flag' => array('type' => 'integer', 'null' => false, 'length' => 1, 'default' => 0)
);
}
View
8 lib/Cake/Test/Fixture/NumberTreeFixture.php
@@ -35,10 +35,10 @@ class NumberTreeFixture extends CakeTestFixture {
* @var array
*/
public $fields = array(
- 'id' => array('type' => 'integer','key' => 'primary'),
- 'name' => array('type' => 'string','null' => false),
+ 'id' => array('type' => 'integer', 'key' => 'primary'),
+ 'name' => array('type' => 'string', 'null' => false),
'parent_id' => 'integer',
- 'lft' => array('type' => 'integer','null' => false),
- 'rght' => array('type' => 'integer','null' => false)
+ 'lft' => array('type' => 'integer', 'null' => false),
+ 'rght' => array('type' => 'integer', 'null' => false)
);
}
View
8 lib/Cake/Test/Fixture/NumberTreeTwoFixture.php
@@ -35,11 +35,11 @@ class NumberTreeTwoFixture extends CakeTestFixture {
* @var array
*/
public $fields = array(
- 'id' => array('type' => 'integer','key' => 'primary'),
- 'name' => array('type' => 'string','null' => false),
+ 'id' => array('type' => 'integer', 'key' => 'primary'),
+ 'name' => array('type' => 'string', 'null' => false),
'number_tree_id' => array('type' => 'integer', 'null' => false),
'parent_id' => 'integer',
- 'lft' => array('type' => 'integer','null' => false),
- 'rght' => array('type' => 'integer','null' => false)
+ 'lft' => array('type' => 'integer', 'null' => false),
+ 'rght' => array('type' => 'integer', 'null' => false)
);
}
View
8 lib/Cake/Test/Fixture/UnconventionalTreeFixture.php
@@ -34,10 +34,10 @@ class UnconventionalTreeFixture extends CakeTestFixture {
* @var array
*/
public $fields = array(
- 'id' => array('type' => 'integer','key' => 'primary'),
- 'name' => array('type' => 'string','null' => false),
+ 'id' => array('type' => 'integer', 'key' => 'primary'),
+ 'name' => array('type' => 'string', 'null' => false),
'join' => 'integer',
- 'left' => array('type' => 'integer','null' => false),
- 'right' => array('type' => 'integer','null' => false),
+ 'left' => array('type' => 'integer', 'null' => false),
+ 'right' => array('type' => 'integer', 'null' => false),
);
}
View
6 lib/Cake/Utility/CakeNumber.php
@@ -43,7 +43,7 @@ class CakeNumber {
),
'GBP' => array(
'wholeSymbol' => '&#163;', 'wholePosition' => 'before', 'fractionSymbol' => 'p', 'fractionPosition' => 'after',
- 'zero' => 0, 'places' => 2, 'thousands' => ',', 'decimals' => '.', 'negative' => '()','escape' => false
+ 'zero' => 0, 'places' => 2, 'thousands' => ',', 'decimals' => '.', 'negative' => '()', 'escape' => false
),
'EUR' => array(
'wholeSymbol' => '&#8364;', 'wholePosition' => 'before', 'fractionSymbol' => false, 'fractionPosition' => 'after',
@@ -58,7 +58,7 @@ class CakeNumber {
*/
protected static $_currencyDefaults = array(
'wholeSymbol' => '', 'wholePosition' => 'before', 'fractionSymbol' => '', 'fractionPosition' => 'after',
- 'zero' => '0', 'places' => 2, 'thousands' => ',', 'decimals' => '.','negative' => '()', 'escape' => true,
+ 'zero' => '0', 'places' => 2, 'thousands' => ',', 'decimals' => '.', 'negative' => '()', 'escape' => true,
);
/**
@@ -317,7 +317,7 @@ public static function currency($value, $currency = null, $options = array()) {
$symbolKey = 'whole';
$value = (float)$value;
if (!$value) {
- if ($options['zero'] !== 0 ) {
+ if ($options['zero'] !== 0) {
return $options['zero'];
}
} elseif ($value < 1 && $value > -1) {
View
2  lib/Cake/Utility/String.php
@@ -524,7 +524,7 @@ class_exists('Multibyte');
}
}
- $truncate .= mb_substr($tag[3], 0 , $left + $entitiesLength);
+ $truncate .= mb_substr($tag[3], 0, $left + $entitiesLength);
break;
} else {
$truncate .= $tag[3];
View
2  lib/Cake/View/Helper.php
@@ -480,7 +480,7 @@ protected function _parseAttributes($options, $exclude = null, $insertBefore = '
*/
protected function _formatAttribute($key, $value, $escape = true) {
if (is_array($value)) {
- $value = implode(' ' , $value);
+ $value = implode(' ', $value);
}
if (is_numeric($key)) {
return sprintf($this->_minimizedAttributeFormat, $value, $value);
Please sign in to comment.
Something went wrong with that request. Please try again.