From 9a538aeb0412f80fe38255f3a727bbce9bbfef68 Mon Sep 17 00:00:00 2001 From: Mark Story Date: Mon, 4 Apr 2016 21:44:31 -0400 Subject: [PATCH] Fix PHPCS mistakes. --- tests/TestCase/View/Helper/FormHelperTest.php | 34 +++++++++---------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/tests/TestCase/View/Helper/FormHelperTest.php b/tests/TestCase/View/Helper/FormHelperTest.php index 3c7af475596..176961e8ad7 100644 --- a/tests/TestCase/View/Helper/FormHelperTest.php +++ b/tests/TestCase/View/Helper/FormHelperTest.php @@ -6988,24 +6988,24 @@ public function testPostLinkSecurityHash() */ public function testPostLinkSecurityHashBlockMode() { - $hash = Security::hash( - '/posts/delete/1' . - serialize([]) . - '' . + $hash = Security::hash( + '/posts/delete/1' . + serialize([]) . + '' . Security::salt() - ); - $hash .= '%3A'; - $this->Form->request->params['_Token']['key'] = 'test'; - - $this->Form->create('Post', ['url' => ['action' => 'add']]); - $this->Form->input('title'); - $this->Form->postLink('Delete', '/posts/delete/1', ['block' => true]); - $result = $this->View->fetch('postLink'); - - $this->assertEquals(['title'], $this->Form->fields); - $this->assertContains($hash, $result, 'Should contain the correct hash.'); - $this->assertAttributeEquals('/articles/add', '_lastAction', $this->Form, 'lastAction was should be restored.'); - } + ); + $hash .= '%3A'; + $this->Form->request->params['_Token']['key'] = 'test'; + + $this->Form->create('Post', ['url' => ['action' => 'add']]); + $this->Form->input('title'); + $this->Form->postLink('Delete', '/posts/delete/1', ['block' => true]); + $result = $this->View->fetch('postLink'); + + $this->assertEquals(['title'], $this->Form->fields); + $this->assertContains($hash, $result, 'Should contain the correct hash.'); + $this->assertAttributeEquals('/articles/add', '_lastAction', $this->Form, 'lastAction was should be restored.'); + } /** * Test that security does not include debug token if debug is false.