Completed
Push — master ( 106d3c...7eed6f )
by amaury
03:05
created
Tests/Functional/ModelBundle/Repository/NodeRepositoryTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -132,7 +132,7 @@  discard block
 block discarded – undo
132 132
         }
133 133
         if (count($nodes) > 1) {
134 134
             for ($i = 1; $i < count($nodes); $i++) {
135
-                $this->assertGreaterThan($nodes[$i]->getVersion(), $nodes[$i-1]->getVersion());
135
+                $this->assertGreaterThan($nodes[$i]->getVersion(), $nodes[$i - 1]->getVersion());
136 136
             }
137 137
         }
138 138
     }
@@ -804,7 +804,7 @@  discard block
 block discarded – undo
804 804
         $dm = static::$kernel->getContainer()->get('object_manager');
805 805
         $nodeNews = $this->repository->findOneByNodeId('fixture_page_news');
806 806
         $nodeCommunity = $this->repository->findOneByNodeId('fixture_page_community');
807
-        $nodeContact= $this->repository->findOneByNodeId('fixture_page_contact');
807
+        $nodeContact = $this->repository->findOneByNodeId('fixture_page_contact');
808 808
         $dm->detach($nodeContact);
809 809
         $dm->detach($nodeCommunity);
810 810
         $dm->detach($nodeNews);
Please login to merge, or discard this patch.
Tests/Functional/UserAdminBundle/Repository/UserRepositoryTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -183,7 +183,7 @@
 block discarded – undo
183 183
      */
184 184
     public function testFindByIncludedUsernameWithoutGroup($username, $groupName, $countUser)
185 185
     {
186
-        $group =  static::$kernel->getContainer()->get('open_orchestra_user.repository.group')->findOneByName($groupName);
186
+        $group = static::$kernel->getContainer()->get('open_orchestra_user.repository.group')->findOneByName($groupName);
187 187
         $users = $this->repository->findByIncludedUsernameWithoutGroup($username, $group);
188 188
 
189 189
         $this->assertCount($countUser, $users);
Please login to merge, or discard this patch.
OpenOrchestra/Tests/Functional/ApiBundle/Controller/ApiControllersTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -19,8 +19,8 @@
 block discarded – undo
19 19
      */
20 20
     public function testApi($url, $getParameter = '', $method = 'GET')
21 21
     {
22
-        $baseGetParameter = '?access_token=' . $this->getAccessToken();
23
-        $this->client->request($method, $url . $baseGetParameter . $getParameter);
22
+        $baseGetParameter = '?access_token='.$this->getAccessToken();
23
+        $this->client->request($method, $url.$baseGetParameter.$getParameter);
24 24
         $this->assertEquals(200, $this->client->getResponse()->getStatusCode());
25 25
         $this->assertSame('application/json', $this->client->getResponse()->headers->get('content-type'));
26 26
     }
Please login to merge, or discard this patch.
Tests/Functional/ModelBundle/Repository/StatustRepositoryTest.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -102,10 +102,10 @@
 block discarded – undo
102 102
      */
103 103
     public function providePaginateConfiguration()
104 104
     {
105
-        $mapping =  array('label' => 'labels');
106
-        $conf1 = PaginateFinderConfiguration::generateFromVariable(null , null, null, $mapping, null);
107
-        $conf2 = PaginateFinderConfiguration::generateFromVariable(null , null, null, $mapping, array('label' => 'o', 'language' => 'en'));
108
-        $conf3 = PaginateFinderConfiguration::generateFromVariable(null , 2   , 4   , $mapping, array('label' => 'r', 'language' => 'en'));
105
+        $mapping = array('label' => 'labels');
106
+        $conf1 = PaginateFinderConfiguration::generateFromVariable(null, null, null, $mapping, null);
107
+        $conf2 = PaginateFinderConfiguration::generateFromVariable(null, null, null, $mapping, array('label' => 'o', 'language' => 'en'));
108
+        $conf3 = PaginateFinderConfiguration::generateFromVariable(null, 2, 4, $mapping, array('label' => 'r', 'language' => 'en'));
109 109
 
110 110
         return array(
111 111
             'No criteria'                => array($conf1, 5, 5),
Please login to merge, or discard this patch.
src/OpenOrchestra/Tests/Functional/ModelBundle/Model/EntityTest.php 1 patch
Spacing   +48 added lines, -48 removed lines patch added patch discarded remove patch
@@ -18,8 +18,8 @@  discard block
 block discarded – undo
18 18
      */
19 19
     public function testInstance($class, $interface)
20 20
     {
21
-        $fullClass = 'OpenOrchestra\ModelBundle\Document\\' . $class;
22
-        $fullInterface = 'OpenOrchestra\ModelInterface\Model\\' . $interface;
21
+        $fullClass = 'OpenOrchestra\ModelBundle\Document\\'.$class;
22
+        $fullInterface = 'OpenOrchestra\ModelInterface\Model\\'.$interface;
23 23
         $entity = new $fullClass();
24 24
 
25 25
         $this->assertInstanceOf($fullInterface, $entity);
@@ -31,53 +31,53 @@  discard block
 block discarded – undo
31 31
     public function providateClassInterfaceRelation()
32 32
     {
33 33
         return array(
34
-            array('Node'                     , 'NodeInterface'),
35
-            array('Node'                     , 'SchemeableInterface'),
36
-            array('Node'                     , 'ReadSchemeableInterface'),
37
-            array('Node'                     , 'VersionableInterface'),
38
-            array('Node'                     , 'SoftDeleteableInterface'),
39
-            array('Node'                     , 'StatusableInterface'),
40
-            array('Content'                  , 'StatusableInterface'),
41
-            array('Content'                  , 'SoftDeleteableInterface'),
42
-            array('Content'                  , 'VersionableInterface'),
43
-            array('Content'                  , 'SiteLinkableInterface'),
44
-            array('ContentType'              , 'SiteLinkableInterface'),
45
-            array('Area'                     , 'AreaInterface'),
46
-            array('Area'                     , 'ReadAreaInterface'),
47
-            array('Block'                    , 'BlockInterface'),
48
-            array('Block'                    , 'ReadBlockInterface'),
49
-            array('Block'                    , 'TimestampableInterface'),
50
-            array('ContentAttribute'         , 'ContentAttributeInterface'),
51
-            array('ContentAttribute'         , 'ReadContentAttributeInterface'),
52
-            array('Content'                  , 'ContentInterface'),
53
-            array('Content'                  ,  'ReadContentInterface'),
54
-            array('ContentType'              , 'ContentTypeInterface'),
55
-            array('ContentType'              , 'SoftDeleteableInterface'),
56
-            array('ContentType'              , 'FieldTypeContainerInterface'),
57
-            array('ContentType'              , 'VersionableInterface'),
58
-            array('FieldType'                , 'FieldTypeInterface'),
59
-            array('FieldOption'              , 'FieldOptionInterface'),
60
-            array('Site'                     , 'SiteInterface'),
61
-            array('Site'                     , 'SoftDeleteableInterface'),
62
-            array('SiteAlias'                , 'SiteAliasInterface'),
63
-            array('SiteAlias'                , 'SchemeableInterface'),
64
-            array('SiteAlias'                , 'ReadSchemeableInterface'),
65
-            array('Node'                     , 'BlameableInterface'),
66
-            array('Content'                  , 'BlameableInterface'),
67
-            array('ContentType'              , 'BlameableInterface'),
68
-            array('Node'                     , 'TimestampableInterface'),
69
-            array('Content'                  , 'TimestampableInterface'),
70
-            array('ContentType'              , 'TimestampableInterface'),
71
-            array('Theme'                    , 'ThemeInterface'),
72
-            array('Keyword'                  , 'KeywordInterface'),
73
-            array('Content'                  , 'KeywordableInterface'),
74
-            array('Redirection'              , 'RedirectionInterface'),
75
-            array('Redirection'              , 'ReadRedirectionInterface'),
76
-            array('TrashItem'                , 'TrashItemInterface'),
77
-            array('RouteDocument'            , 'RouteDocumentInterface'),
78
-            array('WorkflowProfile'          , 'WorkflowProfileInterface'),
34
+            array('Node', 'NodeInterface'),
35
+            array('Node', 'SchemeableInterface'),
36
+            array('Node', 'ReadSchemeableInterface'),
37
+            array('Node', 'VersionableInterface'),
38
+            array('Node', 'SoftDeleteableInterface'),
39
+            array('Node', 'StatusableInterface'),
40
+            array('Content', 'StatusableInterface'),
41
+            array('Content', 'SoftDeleteableInterface'),
42
+            array('Content', 'VersionableInterface'),
43
+            array('Content', 'SiteLinkableInterface'),
44
+            array('ContentType', 'SiteLinkableInterface'),
45
+            array('Area', 'AreaInterface'),
46
+            array('Area', 'ReadAreaInterface'),
47
+            array('Block', 'BlockInterface'),
48
+            array('Block', 'ReadBlockInterface'),
49
+            array('Block', 'TimestampableInterface'),
50
+            array('ContentAttribute', 'ContentAttributeInterface'),
51
+            array('ContentAttribute', 'ReadContentAttributeInterface'),
52
+            array('Content', 'ContentInterface'),
53
+            array('Content', 'ReadContentInterface'),
54
+            array('ContentType', 'ContentTypeInterface'),
55
+            array('ContentType', 'SoftDeleteableInterface'),
56
+            array('ContentType', 'FieldTypeContainerInterface'),
57
+            array('ContentType', 'VersionableInterface'),
58
+            array('FieldType', 'FieldTypeInterface'),
59
+            array('FieldOption', 'FieldOptionInterface'),
60
+            array('Site', 'SiteInterface'),
61
+            array('Site', 'SoftDeleteableInterface'),
62
+            array('SiteAlias', 'SiteAliasInterface'),
63
+            array('SiteAlias', 'SchemeableInterface'),
64
+            array('SiteAlias', 'ReadSchemeableInterface'),
65
+            array('Node', 'BlameableInterface'),
66
+            array('Content', 'BlameableInterface'),
67
+            array('ContentType', 'BlameableInterface'),
68
+            array('Node', 'TimestampableInterface'),
69
+            array('Content', 'TimestampableInterface'),
70
+            array('ContentType', 'TimestampableInterface'),
71
+            array('Theme', 'ThemeInterface'),
72
+            array('Keyword', 'KeywordInterface'),
73
+            array('Content', 'KeywordableInterface'),
74
+            array('Redirection', 'RedirectionInterface'),
75
+            array('Redirection', 'ReadRedirectionInterface'),
76
+            array('TrashItem', 'TrashItemInterface'),
77
+            array('RouteDocument', 'RouteDocumentInterface'),
78
+            array('WorkflowProfile', 'WorkflowProfileInterface'),
79 79
             array('WorkflowProfileCollection', 'WorkflowProfileCollectionInterface'),
80
-            array('WorkflowTransition'       , 'WorkflowTransitionInterface'),
80
+            array('WorkflowTransition', 'WorkflowTransitionInterface'),
81 81
         );
82 82
     }
83 83
 }
Please login to merge, or discard this patch.
Tests/Functional/ModelLogBundle/Repository/LogRepositoryTest.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -56,16 +56,16 @@
 block discarded – undo
56 56
             'user_name' => 'extra.user_name',
57 57
             'message'   => 'message'
58 58
         );
59
-        $conf1 = PaginateFinderConfiguration::generateFromVariable(null , null, null, $mapping, array(
59
+        $conf1 = PaginateFinderConfiguration::generateFromVariable(null, null, null, $mapping, array(
60 60
             'site_id' => 'fixture'
61 61
         ));
62
-        $conf2 = PaginateFinderConfiguration::generateFromVariable(null , null, null, $mapping, array(
62
+        $conf2 = PaginateFinderConfiguration::generateFromVariable(null, null, null, $mapping, array(
63 63
             'site_id' => 'fixture', 'date' => '2016/02/10', 'date-format' => 'yy/mm/dd'
64 64
         ));
65
-        $conf3 = PaginateFinderConfiguration::generateFromVariable(null , null, null, $mapping, array(
65
+        $conf3 = PaginateFinderConfiguration::generateFromVariable(null, null, null, $mapping, array(
66 66
             'site_id' => 'fixture', 'user_ip' => '5'
67 67
         ));
68
-        $conf4 = PaginateFinderConfiguration::generateFromVariable(null , null, null, $mapping, array(
68
+        $conf4 = PaginateFinderConfiguration::generateFromVariable(null, null, null, $mapping, array(
69 69
             'site_id' => 'fixture', 'user_name' => 'developer'
70 70
         ));
71 71
 
Please login to merge, or discard this patch.
Tests/Functional/ModelBundle/Repository/ContentRepositoryTest.php 1 patch
Spacing   +24 added lines, -24 removed lines patch added patch discarded remove patch
@@ -160,7 +160,7 @@  discard block
 block discarded – undo
160 160
     {
161 161
         return array(
162 162
             array('car', ContentRepositoryInterface::CHOICE_AND, 'lorem', 3),
163
-            array('car',ContentRepositoryInterface::CHOICE_AND, 'sit', 1),
163
+            array('car', ContentRepositoryInterface::CHOICE_AND, 'sit', 1),
164 164
             array('car', ContentRepositoryInterface::CHOICE_AND, 'dolor', 0),
165 165
             array('car', ContentRepositoryInterface::CHOICE_AND, 'sit AND lorem', 1),
166 166
             array('news', ContentRepositoryInterface::CHOICE_AND, 'lorem', 1),
@@ -301,7 +301,7 @@  discard block
 block discarded – undo
301 301
             'fields.tinimce_test.string_value' => 'attributes.tinimce_test.stringValue',
302 302
         );
303 303
 
304
-        $searchTypes = array (
304
+        $searchTypes = array(
305 305
             'attributes.car_name' => 'text',
306 306
             'attributes.description' => 'text',
307 307
             'attributes.on_market' => 'date',
@@ -313,7 +313,7 @@  discard block
 block discarded – undo
313 313
         $contents = $this->repository->findForPaginateFilterByContentTypeSiteAndLanguage($configuration, $contentType, $siteId, $language, $searchTypes);
314 314
         $repositoryCount = $this->repository->countWithFilterAndContentTypeSiteAndLanguage($configuration, $contentType, $siteId, $language, $searchTypes);
315 315
 
316
-        if(!is_null($name)) {
316
+        if (!is_null($name)) {
317 317
             $this->assertEquals($name, $contents[0]->getName());
318 318
         }
319 319
         $this->assertCount($count, $contents);
@@ -326,16 +326,16 @@  discard block
 block discarded – undo
326 326
     public function provideContentTypeAndPaginateAndSearchAndsiteId()
327 327
     {
328 328
         return array(
329
-            1  => array('car', null, array("name" => "name", "dir" => "asc"), '2', 0 ,5 , 'en', 3, 3, '206 3 portes en'),
330
-            2  => array('car', null, array("name" => "name", "dir" => "desc"), '2', 0 ,5 , 'en', 3, 3, 'R5 3 portes en'),
331
-            3  => array('car', null, array("name" => "fields.car_name.string_value", "dir" => "asc"), '2', 0 ,5 , 'en', 3, 3, '206 3 portes en'),
332
-            4  => array('car', null, array("name" => "fields.car_name.string_value", "dir" => "desc"),'2', 0 ,5 , 'en', 3, 3, 'R5 3 portes en'),
333
-            5  => array('car', null, null, null, 0 ,1 , 'en', 1, 2),
334
-            6  => array('car', array('attributes.car_name' => '206'), null, '2', 0 , 2 , 'en', 1, 1),
335
-            7  => array('news', null, null, '2', 0 , 100, 'fr', 4, 4),
336
-            8  => array('news', null, null, '2', 50 , 100, 'en', 0, 0),
337
-            9 => array('news', array('name' => 'news'), null, '2', 0 , null, 'fr', 0, 0),
338
-            10 => array('car', null, null, '2', 0 ,5 , 'en', 3, 3),
329
+            1  => array('car', null, array("name" => "name", "dir" => "asc"), '2', 0, 5, 'en', 3, 3, '206 3 portes en'),
330
+            2  => array('car', null, array("name" => "name", "dir" => "desc"), '2', 0, 5, 'en', 3, 3, 'R5 3 portes en'),
331
+            3  => array('car', null, array("name" => "fields.car_name.string_value", "dir" => "asc"), '2', 0, 5, 'en', 3, 3, '206 3 portes en'),
332
+            4  => array('car', null, array("name" => "fields.car_name.string_value", "dir" => "desc"), '2', 0, 5, 'en', 3, 3, 'R5 3 portes en'),
333
+            5  => array('car', null, null, null, 0, 1, 'en', 1, 2),
334
+            6  => array('car', array('attributes.car_name' => '206'), null, '2', 0, 2, 'en', 1, 1),
335
+            7  => array('news', null, null, '2', 0, 100, 'fr', 4, 4),
336
+            8  => array('news', null, null, '2', 50, 100, 'en', 0, 0),
337
+            9 => array('news', array('name' => 'news'), null, '2', 0, null, 'fr', 0, 0),
338
+            10 => array('car', null, null, '2', 0, 5, 'en', 3, 3),
339 339
         );
340 340
     }
341 341
 
@@ -470,63 +470,63 @@  discard block
 block discarded – undo
470 470
      */
471 471
     protected function getDescriptionColumnEntity()
472 472
     {
473
-        return array (
473
+        return array(
474 474
             'name' =>
475
-            array (
475
+            array(
476 476
                 'key' => 'name',
477 477
                 'field' => 'name',
478 478
                 'type' => 'string',
479 479
             ),
480 480
             'language' =>
481
-            array (
481
+            array(
482 482
                 'key' => 'language',
483 483
                 'field' => 'language',
484 484
                 'type' => 'string',
485 485
             ),
486 486
             'status_label' =>
487
-            array (
487
+            array(
488 488
                 'key' => 'status_label',
489 489
                 'field' => 'status',
490 490
                 'type' => 'multiLanguages',
491 491
             ),
492 492
             'version' =>
493
-            array (
493
+            array(
494 494
                 'key' => 'version',
495 495
                 'field' => 'version',
496 496
                 'type' => 'integer',
497 497
             ),
498 498
             'linked_to_site' =>
499
-            array (
499
+            array(
500 500
                 'key' => 'linked_to_site',
501 501
                 'field' => 'linkedTosite',
502 502
                 'type' => 'boolean',
503 503
             ),
504 504
             'created_by' =>
505
-            array (
505
+            array(
506 506
                 'key' => 'created_by',
507 507
                 'field' => 'createdBy',
508 508
                 'type' => 'string',
509 509
             ),
510 510
             'updated_by' =>
511
-            array (
511
+            array(
512 512
                 'key' => 'updated_by',
513 513
                 'field' => 'updatedBy',
514 514
                 'type' => 'string',
515 515
             ),
516 516
             'created_at' =>
517
-            array (
517
+            array(
518 518
                 'key' => 'created_at',
519 519
                 'field' => 'createdAt',
520 520
                 'type' => 'date',
521 521
             ),
522 522
             'updated_at' =>
523
-            array (
523
+            array(
524 524
                 'key' => 'updated_at',
525 525
                 'field' => 'updatedAt',
526 526
                 'type' => 'date',
527 527
             ),
528 528
             'deleted' =>
529
-            array (
529
+            array(
530 530
                 'key' => 'deleted',
531 531
                 'field' => 'deleted',
532 532
                 'type' => 'boolean',
Please login to merge, or discard this patch.
Tests/Functional/ModelBundle/Repository/BlockRepositoryTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@
 block discarded – undo
48 48
     public function provideLanguageAndVersionListAndSiteId()
49 49
     {
50 50
         return array(
51
-            array(0,'fake_component', 'en', '2'),
51
+            array(0, 'fake_component', 'en', '2'),
52 52
             array(2, 'tiny_mce_wysiwyg', 'fr', '2'),
53 53
             array(2, 'tiny_mce_wysiwyg', 'en', '2'),
54 54
             array(1, 'menu', 'en', '2'),
Please login to merge, or discard this patch.
Tests/Functional/BackofficeBundle/Command/PublishElementCommandTrait.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -28,13 +28,13 @@  discard block
 block discarded – undo
28 28
 
29 29
         $commandTester->execute(array('command' => $command->getName()));
30 30
         $this->assertRegExp(
31
-            '/Publishing '.$entityName.'s for siteId ' . $siteId . '/',
31
+            '/Publishing '.$entityName.'s for siteId '.$siteId.'/',
32 32
             $commandTester->getDisplay()
33 33
         );
34 34
 
35 35
         foreach ($elements as $element) {
36 36
             $this->assertRegExp(
37
-                '/-> ' . $element->getName() . ' \(v' . $element->getVersion() . ' ' . $element->getLanguage() . '\) published/',
37
+                '/-> '.$element->getName().' \(v'.$element->getVersion().' '.$element->getLanguage().'\) published/',
38 38
                 $commandTester->getDisplay()
39 39
             );
40 40
         }
@@ -60,13 +60,13 @@  discard block
 block discarded – undo
60 60
 
61 61
         $commandTester->execute(array('command' => $command->getName()));
62 62
         $this->assertRegExp(
63
-            '/Unpublishing '.$entityName.'s for siteId ' . $siteId . '/',
63
+            '/Unpublishing '.$entityName.'s for siteId '.$siteId.'/',
64 64
             $commandTester->getDisplay()
65 65
         );
66 66
 
67 67
         foreach ($elements as $element) {
68 68
             $this->assertRegExp(
69
-                '/-> ' . $element->getName() . ' \(v' . $element->getVersion() . ' ' . $element->getLanguage() . '\) unpublished/',
69
+                '/-> '.$element->getName().' \(v'.$element->getVersion().' '.$element->getLanguage().'\) unpublished/',
70 70
                 $commandTester->getDisplay()
71 71
             );
72 72
         }
Please login to merge, or discard this patch.