Commit 876a1b18 authored by catch's avatar catch

Issue #2056293 by sauravshrestha: Remove empty test...

Issue #2056293 by sauravshrestha: Remove empty test Drupal\node\Tests\NodeEntityFieldQueryAlterTest.
parent ab69f178
<?php
/**
* @file
* Definition of Drupal\node\Tests\NodeEntityFieldQueryAlterTest.
*/
namespace Drupal\node\Tests;
use Drupal\Core\Language\Language;
/**
* Tests node_query_entity_field_access_alter().
*/
class NodeEntityFieldQueryAlterTest extends NodeTestBase {
/**
* Modules to enable.
*
* @var array
*/
public static $modules = array('node_access_test');
public static function getInfo() {
return array(
'name' => 'Node entity query alter',
'description' => 'Test that node access entity queries are properly altered by the node module.',
'group' => 'Node',
);
}
/**
* User with permission to view content.
*/
protected $accessUser;
/**
* User without permission to view content.
*/
protected $noAccessUser;
function setUp() {
parent::setUp();
node_access_rebuild();
// Creating 4 nodes with an entity field so we can test that sort of query
// alter. All field values starts with 'A' so we can identify and fetch them
// in the node_access_test module.
$settings = array('langcode' => Language::LANGCODE_NOT_SPECIFIED);
for ($i = 0; $i < 4; $i++) {
$body = array(
'value' => 'A' . $this->randomName(32),
'format' => filter_default_format(),
);
$settings['body'][0] = $body;
$this->drupalCreateNode($settings);
}
// Create user with simple node access permission. The 'node test view'
// permission is implemented and granted by the node_access_test module.
$this->accessUser = $this->drupalCreateUser(array('access content', 'node test view'));
$this->noAccessUser = $this->drupalCreateUser(array('access content'));
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment