.../lib/Drupal/block/Tests/Views/DisplayBlockTest.php | 2 +- .../contextual/Tests/ContextualDynamicContextTest.php | 2 +- .../modules/edit/lib/Drupal/edit/Tests/EditLoadingTest.php | 12 ++++++------ .../lib/Drupal/editor/Tests/EditIntegrationLoadingTest.php | 4 ++-- core/modules/menu/lib/Drupal/menu/Tests/MenuTest.php | 2 +- .../simpletest/lib/Drupal/simpletest/WebTestBase.php | 2 +- .../views_ui/lib/Drupal/views_ui/Tests/DisplayTest.php | 2 +- 7 files changed, 13 insertions(+), 13 deletions(-) diff --git a/core/modules/block/lib/Drupal/block/Tests/Views/DisplayBlockTest.php b/core/modules/block/lib/Drupal/block/Tests/Views/DisplayBlockTest.php index 9d8a66b..3e192b1 100644 --- a/core/modules/block/lib/Drupal/block/Tests/Views/DisplayBlockTest.php +++ b/core/modules/block/lib/Drupal/block/Tests/Views/DisplayBlockTest.php @@ -163,7 +163,7 @@ public function testBlockContextualLinks() { // Get server-rendered contextual links. // @see \Drupal\contextual\Tests\ContextualDynamicContextTest:renderContextualLinks() $post = array('ids[0]' => $id); - $response = $this->drupalPostCustom('contextual/render', 'application/json', $post, array('query' => array('destination' => 'test-page'))); + $response = $this->drupalPostUrl('contextual/render', 'application/json', $post, array('query' => array('destination' => 'test-page'))); $this->assertResponse(200); $json = drupal_json_decode($response); $this->assertIdentical($json[$id], '
'); diff --git a/core/modules/contextual/lib/Drupal/contextual/Tests/ContextualDynamicContextTest.php b/core/modules/contextual/lib/Drupal/contextual/Tests/ContextualDynamicContextTest.php index 3459ac8..82c7e73 100644 --- a/core/modules/contextual/lib/Drupal/contextual/Tests/ContextualDynamicContextTest.php +++ b/core/modules/contextual/lib/Drupal/contextual/Tests/ContextualDynamicContextTest.php @@ -151,6 +151,6 @@ protected function renderContextualLinks($ids, $current_path) { for ($i = 0; $i < count($ids); $i++) { $post['ids[' . $i . ']'] = $ids[$i]; } - return $this->drupalPostCustom('contextual/render', 'application/json', $post, array('query' => array('destination' => $current_path))); + return $this->drupalPostUrl('contextual/render', 'application/json', $post, array('query' => array('destination' => $current_path))); } } diff --git a/core/modules/edit/lib/Drupal/edit/Tests/EditLoadingTest.php b/core/modules/edit/lib/Drupal/edit/Tests/EditLoadingTest.php index 4b1d74a..66c5115 100644 --- a/core/modules/edit/lib/Drupal/edit/Tests/EditLoadingTest.php +++ b/core/modules/edit/lib/Drupal/edit/Tests/EditLoadingTest.php @@ -87,7 +87,7 @@ function testUserWithoutPermission() { // Retrieving the metadata should result in an empty 403 response. $post = array('fields[0]' => 'node/1/body/und/full'); - $response = $this->drupalPostCustom('edit/metadata', 'application/json', $post); + $response = $this->drupalPostUrl('edit/metadata', 'application/json', $post); $this->assertIdentical('{}', $response); $this->assertResponse(403); } @@ -143,7 +143,7 @@ function testUserWithPermission() { // Retrieving the metadata should result in a 200 JSON response. $htmlPageDrupalSettings = $this->drupalSettings; $post = array('fields[0]' => 'node/1/body/und/full'); - $response = $this->drupalPostCustom('edit/metadata', 'application/json', $post); + $response = $this->drupalPostUrl('edit/metadata', 'application/json', $post); $this->assertResponse(200); $expected = array( 'node/1/body/und/full' => array( @@ -162,7 +162,7 @@ function testUserWithPermission() { // 1. a settings command with useless metadata: AjaxController is dumb // 2. an insert command that loads the required in-place editors $post = array('editors[0]' => 'form') + $this->getAjaxPageStatePostData(); - $response = $this->drupalPostCustom('edit/attachments', 'application/vnd.drupal-ajax', $post); + $response = $this->drupalPostUrl('edit/attachments', 'application/vnd.drupal-ajax', $post); $ajax_commands = drupal_json_decode($response); $this->assertIdentical(2, count($ajax_commands), 'The attachments HTTP request results in two AJAX commands.'); // First command: settings. @@ -175,7 +175,7 @@ function testUserWithPermission() { // Retrieving the form for this field should result in a 200 response, // containing only an editFieldForm command. $post = array('nocssjs' => 'true') + $this->getAjaxPageStatePostData(); - $response = $this->drupalPostCustom('edit/form/' . 'node/1/body/und/full', 'application/vnd.drupal-ajax', $post); + $response = $this->drupalPostUrl('edit/form/' . 'node/1/body/und/full', 'application/vnd.drupal-ajax', $post); $this->assertResponse(200); $ajax_commands = drupal_json_decode($response); $this->assertIdentical(1, count($ajax_commands), 'The field form HTTP request results in one AJAX command.'); @@ -202,7 +202,7 @@ function testUserWithPermission() { // Submit field form and check response. This should store the // updated entity in TempStore on the server. - $response = $this->drupalPostCustom('edit/form/' . 'node/1/body/und/full', 'application/vnd.drupal-ajax', $post); + $response = $this->drupalPostUrl('edit/form/' . 'node/1/body/und/full', 'application/vnd.drupal-ajax', $post); $this->assertResponse(200); $ajax_commands = drupal_json_decode($response); $this->assertIdentical(1, count($ajax_commands), 'The field form HTTP request results in one AJAX command.'); @@ -215,7 +215,7 @@ function testUserWithPermission() { // Save the entity by moving the TempStore values to entity storage. $post = array('nocssjs' => 'true'); - $response = $this->drupalPostCustom('edit/entity/' . 'node/1', 'application/json', $post); + $response = $this->drupalPostUrl('edit/entity/' . 'node/1', 'application/json', $post); $this->assertResponse(200); $ajax_commands = drupal_json_decode($response); $this->assertIdentical(1, count($ajax_commands), 'The entity submission HTTP request results in one AJAX command.'); diff --git a/core/modules/editor/lib/Drupal/editor/Tests/EditIntegrationLoadingTest.php b/core/modules/editor/lib/Drupal/editor/Tests/EditIntegrationLoadingTest.php index 6b85a70..113719b 100644 --- a/core/modules/editor/lib/Drupal/editor/Tests/EditIntegrationLoadingTest.php +++ b/core/modules/editor/lib/Drupal/editor/Tests/EditIntegrationLoadingTest.php @@ -93,7 +93,7 @@ function testUsersWithoutPermission() { $this->assertRaw('Do you also love Drupal?

Do you also love Drupal?
